mumuki-laboratory 6.0.0 → 6.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f1256a63d5d739814865604be435e85b3dfaf992f5e6a3b1f422a111621cdc0a
4
- data.tar.gz: 07053f524225614515baf946df14b9550b9888bc59243e2f191b8a20486232bf
3
+ metadata.gz: 4baab2d6431fb7c2b847f565d313b72d9f6ff8ae9fa1f936d689facccb713139
4
+ data.tar.gz: a8e6210c1a86ff9bd5a1a4b79365d269fa551422d222269cfab4224bce046bd6
5
5
  SHA512:
6
- metadata.gz: 5bc31d21df4fa1e01a079e97039f89216ec14329ab913794cb245f8aa17ece3bca16969c96810c49cc8534388883df2110e9e68e1af0ddcbdf0a57d7b4e8d79a
7
- data.tar.gz: 88f6735bf84a8d7a0b8848eca7c9f90a879234df632cbee98424f8d04fa18f3f45948516324ebe62b27eb96b5fce8a32acda59da4959a08f5ae5f8aeb951d7b2
6
+ metadata.gz: 931eaf49de3e73a34b828237c2975e35c8db05d9aa25b1483fee59acb80343bcb3d89bd2b32f48a710c6040c6b2b1d0daf40d4c748a46f09e1e9ebae1ec1d8fd
7
+ data.tar.gz: 599ef618b7cf04949dbaa40130d9e3d1cc5cb537c13c58cbdc92e71159769938a28a26eb8611b6a06dbc7332584c446f2250c1b5c0e782ae6d037d573bee45cb
@@ -2,7 +2,6 @@ require 'mumukit/core'
2
2
 
3
3
  I18n.load_translations_path File.join(__dir__, 'laboratory', 'locales', '*.yml')
4
4
 
5
- require 'mumuki/laboratory/engine'
6
5
 
7
6
  module Mumuki
8
7
  module Laboratory
@@ -45,3 +44,4 @@ end
45
44
 
46
45
  require_relative './laboratory/extensions'
47
46
  require_relative './laboratory/controllers'
47
+ require_relative './laboratory/engine'
@@ -43,7 +43,6 @@ en:
43
43
  continue_exercise: "Continue"
44
44
  continue_lesson: Continue this lesson!
45
45
  continue_practicing: Continue practicing!
46
- contributors: Contributors
47
46
  corollary: To think about
48
47
  correct_answer: The answer is correct!
49
48
  create_submission: Submit
@@ -47,7 +47,6 @@ es:
47
47
  continue_exercise: "Continuar"
48
48
  continue_lesson: ¡Continuá esta lección!
49
49
  continue_practicing: ¡Seguí aprendiendo!
50
- contributors: Autores
51
50
  correct_answer: ¡La respuesta es correcta!
52
51
  create_submission: Enviar
53
52
  created_at: Creado
@@ -41,7 +41,6 @@ pt:
41
41
  continue_exercise: Continuar
42
42
  continue_lesson: Continue esta lição!
43
43
  continue_practicing: Continue aprendendo!
44
- contributors: Autores
45
44
  correct_answer: A resposta está correta!
46
45
  create_submission: Enviar
47
46
  created_at: Criado
@@ -1,5 +1,5 @@
1
1
  module Mumuki
2
2
  module Laboratory
3
- VERSION = '6.0.0'
3
+ VERSION = '6.0.1'
4
4
  end
5
5
  end
@@ -10,7 +10,7 @@
10
10
  #
11
11
  # It's strongly recommended that you check this file into your version control system.
12
12
 
13
- ActiveRecord::Schema.define(version: 20181114201620) do
13
+ ActiveRecord::Schema.define(version: 20181117190241) do
14
14
 
15
15
  # These are extensions that must be enabled in order to support this database
16
16
  enable_extension "plpgsql"
@@ -223,6 +223,7 @@ ActiveRecord::Schema.define(version: 20181114201620) do
223
223
  t.string "editor_css_urls", default: [], array: true
224
224
  t.string "test_extension"
225
225
  t.text "test_template"
226
+ t.boolean "feedback"
226
227
  t.index ["name"], name: "index_languages_on_name", unique: true
227
228
  end
228
229
 
@@ -10,112 +10,47 @@ describe Language do
10
10
  end
11
11
 
12
12
  describe '#import!' do
13
- let(:bridge) { Mumukit::Bridge::Runner.new('http://runner.com') }
14
- before { expect(bridge).to receive(:info).and_return response }
15
- before { subject.import_from_resource_h! bridge.importable_info }
13
+ subject { create(:language, name: 'gobstones', runner_url: 'http://runner.com') }
14
+ before { subject.import_from_resource_h! language_resource_h }
16
15
 
17
- context 'non graphical language' do
18
- subject { create(:language, name: 'ruby') }
19
- let(:response) do
20
- {
21
- 'name' => 'ruby',
22
- 'version' => 'master',
23
- 'escualo_base_version' => nil,
24
- 'escualo_service_version' => nil,
25
- 'mumukit_version' => '1.0.1',
26
- 'output_content_type' => 'markdown',
27
- 'features' => {
28
- 'query' => true,
29
- 'expectations' => false,
30
- 'feedback' => false,
31
- 'secure' => false,
32
- 'sandboxed' => true,
33
- 'stateful' => true,
34
- 'structured' => true
35
- },
36
- 'language' => {
37
- 'prompt' => '>',
38
- 'name' => 'ruby',
39
- 'version' => '2.0',
40
- 'extension' => 'rb',
41
- 'ace_mode' => 'ruby'
42
- },
43
- 'test_framework' => {
44
- 'name' => 'rspec',
45
- 'version' => '2.13',
46
- 'test_extension' => '.rb'
47
- },
48
- 'url' => 'http://ruby.runners.mumuki.io/info'
49
- }
50
- end
16
+ let(:language_resource_h) { {
17
+ name: "gobstones",
18
+ comment_type: nil,
19
+ runner_url: "http://foo",
20
+ output_content_type: "html",
21
+ prompt: "ム ",
22
+ extension: "gbs",
23
+ highlight_mode: "gobstones",
24
+ visible_success_output: true,
25
+ devicon: nil,
26
+ triable: false,
27
+ feedback: true,
28
+ queriable: false,
29
+ stateful_console: false,
30
+ test_extension: "yml",
31
+ test_template: nil,
32
+ layout_js_urls: ['http://runner.com/javascripts/a.js'],
33
+ layout_html_urls: ["http://runner.com/b.html", "http://runner.com/c.html"],
34
+ layout_css_urls: ["http://runner.com/stylesheets/d.css"],
35
+ editor_js_urls: ['http://runner.com/javascripts/aa.js'],
36
+ editor_html_urls: ["http://runner.com/bb.html", "http://runner.com/cc.html"],
37
+ editor_css_urls: ["http://runner.com/stylesheets/dd.css"]
38
+ } }
51
39
 
52
- it { expect(subject.name).to eq 'ruby' }
53
- it { expect(subject.queriable).to be true }
54
- it { expect(subject.output_content_type).to eq Mumukit::ContentType::Markdown }
55
- it { expect(subject.visible_success_output).to be false }
56
- it { expect(subject.highlight_mode).to eq 'ruby' }
57
- it { expect(subject.devicon).to eq 'ruby' }
58
- it { expect(subject.prompt).to eq '> ' }
59
- it { expect(subject.stateful_console).to be true }
60
- end
61
-
62
- context 'graphical language' do
63
- subject { create(:language, name: 'gobstones', runner_url: 'http://runner.com') }
64
- let(:response) do
65
- {
66
- 'name' => 'gobstones',
67
- 'version' => 'master',
68
- 'escualo_base_version' => nil,
69
- 'escualo_service_version' => nil,
70
- 'mumukit_version' => '1.0.1',
71
- 'output_content_type' => 'html',
72
- 'features' => {
73
- 'query' => false,
74
- 'expectations' => true,
75
- 'feedback' => false,
76
- 'secure' => false,
77
- 'sandboxed' => false,
78
- 'structured' => true
79
- },
80
- 'layout_assets_urls' => {
81
- 'js' => ['javascripts/a.js'],
82
- 'html' => ['b.html', 'c.html'],
83
- 'css' => ['stylesheets/d.css']
84
- },
85
- 'editor_assets_urls' => {
86
- 'js' => ['javascripts/aa.js'],
87
- 'html' => ['bb.html', 'cc.html'],
88
- 'css' => ['stylesheets/dd.css']
89
- },
90
- 'language' => {
91
- 'name' => 'gobstones',
92
- 'graphic' => true,
93
- 'version' => '1.4.1',
94
- 'extension' => 'gbs',
95
- 'ace_mode' => 'gobstones'
96
- },
97
- 'test_framework' => {
98
- 'name' => 'stones-spec',
99
- 'test_extension' => 'yml'
100
- },
101
- 'url' => 'http://runners2.mumuki.io:8001/info'
102
- }
103
- end
104
-
105
- it { expect(subject.name).to eq 'gobstones' }
106
- it { expect(subject.queriable).to be false }
107
- it { expect(subject.output_content_type).to eq Mumukit::ContentType::Html }
108
- it { expect(subject.visible_success_output).to be true }
109
- it { expect(subject.highlight_mode).to eq 'gobstones' }
110
- it { expect(subject.devicon).to eq 'gobstones' }
111
- it { expect(subject.prompt).to eq 'ム ' }
112
- it { expect(subject.stateful_console).to be false }
113
- it { expect(subject.layout_js_urls).to eq ['http://runner.com/javascripts/a.js'] }
114
- it { expect(subject.layout_html_urls).to eq ['http://runner.com/b.html', 'http://runner.com/c.html'] }
115
- it { expect(subject.layout_css_urls).to eq ['http://runner.com/stylesheets/d.css'] }
116
- it { expect(subject.editor_js_urls).to eq ['http://runner.com/javascripts/aa.js'] }
117
- it { expect(subject.editor_html_urls).to eq ['http://runner.com/bb.html', 'http://runner.com/cc.html'] }
118
- it { expect(subject.editor_css_urls).to eq ['http://runner.com/stylesheets/dd.css'] }
119
- end
40
+ it { expect(subject.name).to eq 'gobstones' }
41
+ it { expect(subject.queriable).to be false }
42
+ it { expect(subject.output_content_type).to eq Mumukit::ContentType::Html }
43
+ it { expect(subject.visible_success_output).to be true }
44
+ it { expect(subject.highlight_mode).to eq 'gobstones' }
45
+ it { expect(subject.devicon).to eq 'gobstones' }
46
+ it { expect(subject.prompt).to eq ' ' }
47
+ it { expect(subject.stateful_console).to be false }
48
+ it { expect(subject.feedback).to be true }
49
+ it { expect(subject.layout_js_urls).to eq ['http://runner.com/javascripts/a.js'] }
50
+ it { expect(subject.layout_html_urls).to eq ['http://runner.com/b.html', 'http://runner.com/c.html'] }
51
+ it { expect(subject.layout_css_urls).to eq ['http://runner.com/stylesheets/d.css'] }
52
+ it { expect(subject.editor_js_urls).to eq ['http://runner.com/javascripts/aa.js'] }
53
+ it { expect(subject.editor_html_urls).to eq ['http://runner.com/bb.html', 'http://runner.com/cc.html'] }
54
+ it { expect(subject.editor_css_urls).to eq ['http://runner.com/stylesheets/dd.css'] }
120
55
  end
121
56
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mumuki-laboratory
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.0
4
+ version: 6.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Franco Bulgarelli
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-11-15 00:00:00.000000000 Z
11
+ date: 2018-11-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 6.0.0
33
+ version: 6.0.1
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 6.0.0
40
+ version: 6.0.1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: mumukit-login
43
43
  requirement: !ruby/object:Gem::Requirement