vedeu 0.3.5 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (72) hide show
  1. checksums.yaml +4 -4
  2. data/.ruby-version +1 -1
  3. data/docs/events.md +0 -12
  4. data/examples/configuration_app.rb +1 -1
  5. data/lib/vedeu/all.rb +0 -1
  6. data/lib/vedeu/bindings.rb +18 -3
  7. data/lib/vedeu/buffers/display_buffer.rb +0 -22
  8. data/lib/vedeu/configuration/api.rb +8 -44
  9. data/lib/vedeu/configuration/cli.rb +6 -36
  10. data/lib/vedeu/configuration/configuration.rb +0 -4
  11. data/lib/vedeu/distributed/server.rb +4 -10
  12. data/lib/vedeu/dsl/components/keymap.rb +3 -5
  13. data/lib/vedeu/input/keymap.rb +22 -45
  14. data/lib/vedeu/main_loop.rb +2 -0
  15. data/lib/vedeu/models/focus.rb +1 -1
  16. data/lib/vedeu/models/geometry.rb +2 -2
  17. data/lib/vedeu/models/view/char.rb +1 -1
  18. data/lib/vedeu/models/view/composition.rb +1 -1
  19. data/lib/vedeu/models/view/interface.rb +4 -2
  20. data/lib/vedeu/models/view/line.rb +1 -2
  21. data/lib/vedeu/models/view/stream.rb +1 -1
  22. data/lib/vedeu/output/all.rb +8 -0
  23. data/lib/vedeu/{presentation → output}/background.rb +0 -0
  24. data/lib/vedeu/{presentation → output}/colour.rb +0 -0
  25. data/lib/vedeu/{presentation → output}/foreground.rb +1 -1
  26. data/lib/vedeu/output/html_renderer.rb +13 -30
  27. data/lib/vedeu/{presentation → output}/presentation.rb +0 -0
  28. data/lib/vedeu/{presentation → output}/style.rb +0 -0
  29. data/lib/vedeu/output/templates/html_renderer.vedeu +24 -0
  30. data/lib/vedeu/{presentation → output}/translator.rb +0 -0
  31. data/lib/vedeu/support/log.rb +1 -0
  32. data/test/integration/dsl/compositions_test.rb +0 -8
  33. data/test/integration/dsl/interfaces_test.rb +0 -68
  34. data/test/integration/dsl/keymaps_test.rb +0 -12
  35. data/test/integration/dsl/lines_test.rb +0 -42
  36. data/test/integration/dsl/streams_test.rb +0 -26
  37. data/test/integration/dsl/views_test.rb +0 -18
  38. data/test/lib/vedeu/api_test.rb +0 -97
  39. data/test/lib/vedeu/configuration/api_test.rb +3 -14
  40. data/test/lib/vedeu/configuration/cli_test.rb +0 -14
  41. data/test/lib/vedeu/cursor/cursor_test.rb +0 -2
  42. data/test/lib/vedeu/distributed/client_test.rb +0 -2
  43. data/test/lib/vedeu/distributed/test_application_test.rb +0 -1
  44. data/test/lib/vedeu/dsl/components/keymap_test.rb +1 -7
  45. data/test/lib/vedeu/dsl/components/menu_test.rb +0 -48
  46. data/test/lib/vedeu/dsl/interface_test.rb +1 -263
  47. data/test/lib/vedeu/dsl/shared/text_test.rb +0 -6
  48. data/test/lib/vedeu/dsl/stream_test.rb +0 -2
  49. data/test/lib/vedeu/events/event_test.rb +0 -1
  50. data/test/lib/vedeu/input/keymap_test.rb +8 -2
  51. data/test/lib/vedeu/input/mapper_test.rb +2 -2
  52. data/test/lib/vedeu/launcher_test.rb +0 -12
  53. data/test/lib/vedeu/main_loop_test.rb +0 -17
  54. data/test/lib/vedeu/models/focus_test.rb +59 -19
  55. data/test/lib/vedeu/models/geometry_test.rb +20 -26
  56. data/test/lib/vedeu/models/view/interface_test.rb +0 -27
  57. data/test/lib/vedeu/models/view/stream_test.rb +0 -1
  58. data/test/lib/vedeu/{presentation → output}/background_test.rb +0 -0
  59. data/test/lib/vedeu/{presentation → output}/colour_test.rb +0 -0
  60. data/test/lib/vedeu/output/compositor_test.rb +0 -5
  61. data/test/lib/vedeu/{presentation → output}/foreground_test.rb +0 -0
  62. data/test/lib/vedeu/output/html_renderer_test.rb +1 -0
  63. data/test/lib/vedeu/{presentation → output}/presentation_test.rb +0 -0
  64. data/test/lib/vedeu/{presentation → output}/style_test.rb +0 -0
  65. data/test/lib/vedeu/{presentation → output}/translator_test.rb +0 -0
  66. data/test/lib/vedeu/output/writer_test.rb +8 -21
  67. data/test/lib/vedeu/repositories/repository_test.rb +0 -24
  68. data/test/lib/vedeu/support/refresh_test.rb +0 -10
  69. data/test/support/helpers/model_test_class.rb +1 -1
  70. data/vedeu.gemspec +1 -1
  71. metadata +22 -22
  72. data/lib/vedeu/presentation/all.rb +0 -9
@@ -11,12 +11,13 @@ module Vedeu
11
11
  # @param output [Array<Array<Vedeu::Char>>]
12
12
  # @return [Vedeu::HTMLRenderer]
13
13
  def initialize(output)
14
- @output = output
14
+ @output = output
15
+ @object = self
15
16
  end
16
17
 
17
18
  # @return [String]
18
19
  def render
19
- html_header + html_body + html_footer
20
+ ERB.new(html_output, nil, '-').result(binding)
20
21
  end
21
22
 
22
23
  # @param path [String]
@@ -29,10 +30,6 @@ module Vedeu
29
30
  content
30
31
  end
31
32
 
32
- private
33
-
34
- attr_reader :output
35
-
36
33
  # @return [String]
37
34
  def html_body
38
35
  out = ''
@@ -47,31 +44,12 @@ module Vedeu
47
44
  out
48
45
  end
49
46
 
50
- # @return [String]
51
- def html_header
52
- <<-HTML
53
- <html>
54
- <head>
55
- <style type='text/css'>
56
- body { background:#000; }
57
- td { border:1px #171717 solid;
58
- font-size:12px;
59
- font-family:monospace;
60
- height:18px;
61
- margin:1px;
62
- text-align:center;
63
- vertical-align:center;
64
- width:18px; }
65
- </style>
66
- </head>
67
- <body>
68
- <table>
69
- HTML
70
- end
47
+ private
71
48
 
72
- # @return [String]
73
- def html_footer
74
- "</table></body></html>"
49
+ attr_reader :output
50
+
51
+ def html_output
52
+ @html_output ||= read('html_renderer.vedeu')
75
53
  end
76
54
 
77
55
  # @return [String]
@@ -84,6 +62,11 @@ module Vedeu
84
62
  @timestamp ||= Time.now.to_i
85
63
  end
86
64
 
65
+ # @return [String]
66
+ def read(filename)
67
+ File.read(File.dirname(__FILE__) + '/templates/' + filename)
68
+ end
69
+
87
70
  end # HTMLRenderer
88
71
 
89
72
  end # Vedeu
File without changes
File without changes
@@ -0,0 +1,24 @@
1
+ <html>
2
+ <head>
3
+ <style type='text/css'>
4
+ body {
5
+ background:#000;
6
+ }
7
+ td {
8
+ border:1px #171717 solid;
9
+ font-size:12px;
10
+ font-family:monospace;
11
+ height:18px;
12
+ margin:1px;
13
+ text-align:center;
14
+ vertical-align:center;
15
+ width:18px;
16
+ }
17
+ </style>
18
+ </head>
19
+ <body>
20
+ <table>
21
+ <%= @object.html_body -%>
22
+ </table>
23
+ </body>
24
+ </html>
File without changes
@@ -61,6 +61,7 @@ module Vedeu
61
61
  # @return [Hash]
62
62
  def message_types
63
63
  {
64
+ config: :yellow,
64
65
  create: :green,
65
66
  debug: :red,
66
67
  drb: :blue,
@@ -11,16 +11,8 @@ describe 'Compositions' do
11
11
  end
12
12
  }
13
13
 
14
- #it { subject.must_be_instance_of(Vedeu::Composition) }
15
-
16
- # it 'allows the use of Vedeu.view' do
17
- # skip
18
- # end
19
-
20
14
  context 'when no block is given' do
21
15
  subject { Vedeu.view }
22
-
23
- #it { proc { subject }.must_raise(Vedeu::InvalidSyntax) }
24
16
  end
25
17
  end
26
18
 
@@ -11,10 +11,6 @@ describe 'Interfaces' do
11
11
 
12
12
  it { subject.must_be_instance_of(Vedeu::Interface) }
13
13
 
14
- # it 'allows the use of background within Vedeu.interface' do
15
- # skip
16
- # end
17
-
18
14
  context 'when no value is provided' do
19
15
 
20
16
  end
@@ -30,10 +26,6 @@ describe 'Interfaces' do
30
26
 
31
27
  it { subject.must_be_instance_of(Vedeu::Interface) }
32
28
 
33
- # it 'allows the use of border within Vedeu.interface' do
34
- # skip
35
- # end
36
-
37
29
  context 'when no value is provided' do
38
30
 
39
31
  end
@@ -46,12 +38,6 @@ describe 'Interfaces' do
46
38
  end
47
39
  }
48
40
 
49
- #it { subject.must_be_instance_of(Vedeu::Interface) }
50
-
51
- # it 'allows the use of colour within Vedeu.interface' do
52
- # skip
53
- # end
54
-
55
41
  context 'when no value is provided' do
56
42
 
57
43
  end
@@ -66,10 +52,6 @@ describe 'Interfaces' do
66
52
 
67
53
  it { subject.must_be_instance_of(Vedeu::Interface) }
68
54
 
69
- # it 'allows the use of foreground within Vedeu.interface' do
70
- # skip
71
- # end
72
-
73
55
  context 'when no value is provided' do
74
56
 
75
57
  end
@@ -82,12 +64,6 @@ describe 'Interfaces' do
82
64
  end
83
65
  }
84
66
 
85
- #it { subject.must_be_instance_of(Vedeu::Interface) }
86
-
87
- # it 'allows the use of cursor within Vedeu.interface' do
88
- # skip
89
- # end
90
-
91
67
  context 'when no value is provided' do
92
68
 
93
69
  end
@@ -100,12 +76,6 @@ describe 'Interfaces' do
100
76
  end
101
77
  }
102
78
 
103
- #it { subject.must_be_instance_of(Vedeu::Interface) }
104
-
105
- # it 'allows the use of cursor! within Vedeu.interface' do
106
- # skip
107
- # end
108
-
109
79
  context 'when no value is provided' do
110
80
 
111
81
  end
@@ -120,10 +90,6 @@ describe 'Interfaces' do
120
90
 
121
91
  it { subject.must_be_instance_of(Vedeu::Interface) }
122
92
 
123
- # it 'allows the use of delay within Vedeu.interface' do
124
- # skip
125
- # end
126
-
127
93
  context 'when no value is provided' do
128
94
 
129
95
  end
@@ -136,12 +102,6 @@ describe 'Interfaces' do
136
102
  end
137
103
  }
138
104
 
139
- #it { subject.must_be_instance_of(Vedeu::Interface) }
140
-
141
- # it 'allows the use of focus! within Vedeu.interface' do
142
- # skip
143
- # end
144
-
145
105
  context 'when no value is provided' do
146
106
 
147
107
  end
@@ -157,10 +117,6 @@ describe 'Interfaces' do
157
117
 
158
118
  it { subject.must_be_instance_of(Vedeu::Interface) }
159
119
 
160
- # it 'allows the use of geometry within Vedeu.interface' do
161
- # skip
162
- # end
163
-
164
120
  context 'when no value is provided' do
165
121
 
166
122
  end
@@ -175,10 +131,6 @@ describe 'Interfaces' do
175
131
 
176
132
  it { subject.must_be_instance_of(Vedeu::Interface) }
177
133
 
178
- # it 'allows the use of group within Vedeu.interface' do
179
- # skip
180
- # end
181
-
182
134
  context 'when no value is provided' do
183
135
 
184
136
  end
@@ -192,12 +144,6 @@ describe 'Interfaces' do
192
144
  end
193
145
  }
194
146
 
195
- #it { subject.must_be_instance_of(Vedeu::Interface) }
196
-
197
- # it 'allows the use of keys within Vedeu.interface' do
198
- # skip
199
- # end
200
-
201
147
  context 'when no value is provided' do
202
148
 
203
149
  end
@@ -211,12 +157,6 @@ describe 'Interfaces' do
211
157
  end
212
158
  }
213
159
 
214
- #it { subject.must_be_instance_of(Vedeu::Interface) }
215
-
216
- # it 'allows the use of lines within Vedeu.interface' do
217
- # skip
218
- # end
219
-
220
160
  context 'when no value is provided' do
221
161
 
222
162
  end
@@ -231,10 +171,6 @@ describe 'Interfaces' do
231
171
 
232
172
  it { subject.must_be_instance_of(Vedeu::Interface) }
233
173
 
234
- # it 'allows the use of name within Vedeu.interface' do
235
- # skip
236
- # end
237
-
238
174
  context 'when no value is provided' do
239
175
 
240
176
  end
@@ -249,10 +185,6 @@ describe 'Interfaces' do
249
185
 
250
186
  it { subject.must_be_instance_of(Vedeu::Interface) }
251
187
 
252
- # it 'allows the use of style within Vedeu.interface' do
253
- # skip
254
- # end
255
-
256
188
  context 'when no value is provided' do
257
189
 
258
190
  end
@@ -10,12 +10,6 @@ describe 'Keymaps' do
10
10
  end
11
11
  }
12
12
 
13
- #it { subject.must_be_instance_of(Vedeu::Keymap) }
14
-
15
- # it 'allows the use of ... within Vedeu.keymap' do
16
- # skip
17
- # end
18
-
19
13
  context 'when no value is provided' do
20
14
 
21
15
  end
@@ -28,12 +22,6 @@ describe 'Keymaps' do
28
22
  end
29
23
  }
30
24
 
31
- #it { subject.must_be_instance_of(Vedeu::Keymap) }
32
-
33
- # it 'allows the use of ... within Vedeu.keymap' do
34
- # skip
35
- # end
36
-
37
25
  context 'when no value is provided' do
38
26
 
39
27
  end
@@ -11,12 +11,6 @@ describe 'Lines' do
11
11
  end
12
12
  }
13
13
 
14
- #it { subject.must_be_instance_of(Vedeu::Line) }
15
-
16
- # it 'allows the use of background within lines' do
17
- # skip
18
- # end
19
-
20
14
  context 'when no value is provided' do
21
15
 
22
16
  end
@@ -31,12 +25,6 @@ describe 'Lines' do
31
25
  end
32
26
  }
33
27
 
34
- #it { subject.must_be_instance_of(Vedeu::Line) }
35
-
36
- # it 'allows the use of colour within lines' do
37
- # skip
38
- # end
39
-
40
28
  context 'when no value is provided' do
41
29
 
42
30
  end
@@ -51,12 +39,6 @@ describe 'Lines' do
51
39
  end
52
40
  }
53
41
 
54
- #it { subject.must_be_instance_of(Vedeu::Line) }
55
-
56
- # it 'allows the use of foreground within lines' do
57
- # skip
58
- # end
59
-
60
42
  context 'when no value is provided' do
61
43
 
62
44
  end
@@ -71,12 +53,6 @@ describe 'Lines' do
71
53
  end
72
54
  }
73
55
 
74
- #it { subject.must_be_instance_of(Vedeu::Line) }
75
-
76
- # it 'allows the use of line within lines' do
77
- # skip
78
- # end
79
-
80
56
  context 'when no value is provided' do
81
57
 
82
58
  end
@@ -91,12 +67,6 @@ describe 'Lines' do
91
67
  end
92
68
  }
93
69
 
94
- #it { subject.must_be_instance_of(Vedeu::Line) }
95
-
96
- # it 'allows the use of stream within lines' do
97
- # skip
98
- # end
99
-
100
70
  context 'when no value is provided' do
101
71
 
102
72
  end
@@ -112,12 +82,6 @@ describe 'Lines' do
112
82
  end
113
83
  }
114
84
 
115
- #it { subject.must_be_instance_of(Vedeu::Line) }
116
-
117
- # it 'allows the use of streams within lines' do
118
- # skip
119
- # end
120
-
121
85
  context 'when no value is provided' do
122
86
 
123
87
  end
@@ -132,12 +96,6 @@ describe 'Lines' do
132
96
  end
133
97
  }
134
98
 
135
- #it { subject.must_be_instance_of(Vedeu::Line) }
136
-
137
- # it 'allows the use of style within lines' do
138
- # skip
139
- # end
140
-
141
99
  context 'when no value is provided' do
142
100
 
143
101
  end
@@ -13,11 +13,6 @@ describe 'Streams' do
13
13
  end
14
14
  }
15
15
 
16
- # it 'allows the use of align within stream(s)' do
17
- # skip
18
- # subject.must_equal('Some text')
19
- # end
20
-
21
16
  context 'when no value is provided' do
22
17
 
23
18
  end
@@ -34,10 +29,6 @@ describe 'Streams' do
34
29
  end
35
30
  }
36
31
 
37
- # it 'allows the use of background within stream(s)' do
38
- # skip
39
- # end
40
-
41
32
  context 'when no value is provided' do
42
33
 
43
34
  end
@@ -54,10 +45,6 @@ describe 'Streams' do
54
45
  end
55
46
  }
56
47
 
57
- # it 'allows the use of colour within stream(s)' do
58
- # skip
59
- # end
60
-
61
48
  context 'when no value is provided' do
62
49
 
63
50
  end
@@ -74,10 +61,6 @@ describe 'Streams' do
74
61
  end
75
62
  }
76
63
 
77
- # it 'allows the use of foreground within stream(s)' do
78
- # skip
79
- # end
80
-
81
64
  context 'when no value is provided' do
82
65
 
83
66
  end
@@ -96,10 +79,6 @@ describe 'Streams' do
96
79
  end
97
80
  }
98
81
 
99
- # it 'allows the use of style within stream(s)' do
100
- # skip
101
- # end
102
-
103
82
  context 'when no value is provided' do
104
83
  let(:value) {}
105
84
  end
@@ -116,11 +95,6 @@ describe 'Streams' do
116
95
  end
117
96
  }
118
97
 
119
- # it 'allows the use of text within stream(s)' do
120
- # skip
121
- # subject.must_equal('Some text...')
122
- # end
123
-
124
98
  context 'when no value is provided' do
125
99
 
126
100
  end
@@ -9,12 +9,6 @@ describe 'Views' do
9
9
  end
10
10
  }
11
11
 
12
- #it { subject.must_be_instance_of(Vedeu::Composition) }
13
-
14
- # it 'allows the use of ... within Vedeu.interface' do
15
- # skip
16
- # end
17
-
18
12
  context 'when no value is provided' do
19
13
 
20
14
  end
@@ -27,12 +21,6 @@ describe 'Views' do
27
21
  end
28
22
  }
29
23
 
30
- #it { subject.must_be_instance_of(Vedeu::Composition) }
31
-
32
- # it 'allows the use of ... within Vedeu.renders' do
33
- # skip
34
- # end
35
-
36
24
  context 'when no block is given' do
37
25
  subject { Vedeu.renders }
38
26
 
@@ -47,12 +35,6 @@ describe 'Views' do
47
35
  end
48
36
  }
49
37
 
50
- #it { subject.must_be_instance_of(Vedeu::Composition) }
51
-
52
- # it 'allows the use of ... within Vedeu.views' do
53
- # skip
54
- # end
55
-
56
38
  context 'when no block is given' do
57
39
  subject { Vedeu.views }
58
40
 
@@ -4,63 +4,6 @@ module Vedeu
4
4
 
5
5
  describe API do
6
6
 
7
- # describe '.focus' do
8
- # it 'sets the named interface to be focussed' do
9
- # Interface.build({ name: 'plutonium' }).store
10
-
11
- # Vedeu.expects(:trigger).with(:_focus_by_name_, 'plutonium')
12
-
13
- # Vedeu.focus('plutonium')
14
- # end
15
-
16
- # context 'when the interface is not registered' do
17
- # it { proc { Vedeu.focus('plutonium') }.must_raise(ModelNotFound) }
18
- # end
19
- # end
20
-
21
-
22
-
23
- # describe '.keypress' do
24
- # before do
25
- # Interfaces.reset
26
-
27
- # Vedeu.interface('barium') {}
28
- # end
29
-
30
- # context 'when the key is registered' do
31
- # before do
32
- # Vedeu.keys do
33
- # interface 'barium'
34
- # key('j') { :j_pressed }
35
- # end
36
- # end
37
-
38
- # it 'returns the result of proc stored for the keypress' do
39
- # Vedeu.keypress('j').must_equal(:j_pressed)
40
- # end
41
- # end
42
-
43
- # context 'when the key is not registered' do
44
- # it 'returns false' do
45
- # Vedeu.keypress('k').must_equal(false)
46
- # end
47
- # end
48
- # end
49
-
50
- # describe '.keys' do
51
- # context 'when a block was not given' do
52
- # subject { Vedeu.keys }
53
-
54
- # it { proc { subject }.must_raise(InvalidSyntax) }
55
- # end
56
-
57
- # context 'when a block was given' do
58
- # subject { Vedeu.keys { :some_dsl_methods } }
59
-
60
- # it { subject.must_be_instance_of(Vedeu::Keymap) }
61
- # end
62
- # end
63
-
64
7
  describe '.log' do
65
8
  it 'writes the message to the log file when debugging is enabled' do
66
9
  Configuration.stub(:debug?, true) do
@@ -114,46 +57,6 @@ module Vedeu
114
57
  end
115
58
  end
116
59
 
117
- # describe '.unbind' do
118
- # it 'unregister the event by name' do
119
- # Vedeu.bind(:calcium) { proc { |x| x } }
120
- # Vedeu.events.registered.must_include(:calcium)
121
-
122
- # Vedeu.unbind(:calcium)
123
- # Vedeu.events.registered.wont_include(:calcium)
124
- # end
125
- # end
126
-
127
- # describe '.view' do
128
- # subject { Vedeu.view('holmium') }
129
-
130
- # it { subject.must_be_instance_of(Hash) }
131
- # end
132
-
133
- # describe '.views' do
134
- # it 'allows multiple views to be defined at once' do
135
- # attrs = Vedeu.views do
136
- # view 'view_1' do
137
- # lines do
138
- # text '1. A line of text in view 1.'
139
- # text '2. Another line of text in view 1.'
140
- # end
141
- # end
142
- # view 'view_2' do
143
- # lines do
144
- # text '1. A line of text in view 2.'
145
- # text '2. Another line of text in view 2.'
146
- # end
147
- # end
148
- # end
149
- # attrs[:interfaces].size.must_equal(2)
150
- # end
151
-
152
- # context 'when a block was not given' do
153
- # it { proc { Vedeu.views }.must_raise(InvalidSyntax) }
154
- # end
155
- # end
156
-
157
60
  end # API
158
61
 
159
62
  end # Vedeu
@@ -37,8 +37,6 @@ module Vedeu
37
37
  configuration = Vedeu.configure { interactive }
38
38
  configuration.interactive?.must_equal(true)
39
39
  end
40
-
41
- # it { configuration.must_respond_to(:interactive) }
42
40
  end
43
41
 
44
42
  describe '#standalone!' do
@@ -61,8 +59,6 @@ module Vedeu
61
59
  configuration = Vedeu.configure { standalone }
62
60
  configuration.interactive?.must_equal(false)
63
61
  end
64
-
65
- # it { configuration.must_respond_to(:standalone) }
66
62
  end
67
63
 
68
64
  describe '#run_once!' do
@@ -85,8 +81,6 @@ module Vedeu
85
81
  configuration = Vedeu.configure { run_once }
86
82
  configuration.once.must_equal(true)
87
83
  end
88
-
89
- # it { configuration.must_respond_to(:run_once) }
90
84
  end
91
85
 
92
86
  describe '#drb!' do
@@ -109,8 +103,6 @@ module Vedeu
109
103
  configuration = Vedeu.configure { drb }
110
104
  configuration.drb.must_equal(true)
111
105
  end
112
-
113
- # it { configuration.must_respond_to(:drb) }
114
106
  end
115
107
 
116
108
  describe '#drb_host' do
@@ -146,17 +138,14 @@ module Vedeu
146
138
  configuration = Vedeu.configure { cooked! }
147
139
  configuration.terminal_mode.must_equal(:cooked)
148
140
  end
149
-
150
- # it { configuration.must_respond_to(:cooked) }
151
141
  end
152
142
 
153
143
  describe '#raw!' do
144
+ subject { Vedeu.configure { raw! } }
145
+
154
146
  it 'sets the option to the desired value' do
155
- configuration = Vedeu.configure { raw! }
156
- configuration.terminal_mode.must_equal(:raw)
147
+ subject.terminal_mode.must_equal(:raw)
157
148
  end
158
-
159
- # it { configuration.must_respond_to(:raw) }
160
149
  end
161
150
 
162
151
  describe '#debug!' do
@@ -54,20 +54,6 @@ module Vedeu
54
54
  end
55
55
  end
56
56
 
57
- # describe '#drb_host' do
58
- # it '--drb-host' do
59
- # Configuration.configure(['--drb-host', 'localhost'])
60
- # Configuration.drb_host.must_equal('localhost')
61
- # end
62
- # end
63
-
64
- # describe '#drb_port' do
65
- # it '--drb-port' do
66
- # Configuration.configure(['--drb-port', '12345'])
67
- # Configuration.drb_port.must_equal('12345')
68
- # end
69
- # end
70
-
71
57
  describe '#interactive?' do
72
58
  it '--interactive' do
73
59
  Configuration.configure(['--interactive'])
@@ -28,8 +28,6 @@ module Vedeu
28
28
 
29
29
  describe '#initialize' do
30
30
  it { instance.must_be_instance_of(Cursor) }
31
-
32
- # it { instance.instance_variable_get('@attributes').must_equal() }
33
31
  it { instance.instance_variable_get('@name').must_equal('silver') }
34
32
  it { instance.instance_variable_get('@ox').must_equal(3) }
35
33
  it { instance.instance_variable_get('@oy').must_equal(2) }