vedeu 0.4.23 → 0.4.24

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. checksums.yaml +4 -4
  2. data/examples/cursor_app.rb +9 -4
  3. data/lib/vedeu/bindings.rb +36 -9
  4. data/lib/vedeu/cursor/move.rb +49 -55
  5. data/lib/vedeu/geometry/coordinate.rb +51 -38
  6. data/lib/vedeu/geometry/geometry.rb +44 -16
  7. data/lib/vedeu/geometry/position.rb +2 -6
  8. data/lib/vedeu/input/mapper.rb +2 -0
  9. data/lib/vedeu/models/char.rb +2 -2
  10. data/lib/vedeu/output/all.rb +1 -1
  11. data/lib/vedeu/output/border.rb +8 -6
  12. data/lib/vedeu/output/clear.rb +17 -19
  13. data/lib/vedeu/output/refresh.rb +4 -10
  14. data/lib/vedeu/output/renderers/all.rb +1 -2
  15. data/lib/vedeu/output/renderers/terminal.rb +3 -1
  16. data/lib/vedeu/output/viewport.rb +8 -8
  17. data/lib/vedeu/repositories/collections/all.rb +33 -6
  18. data/lib/vedeu/repositories/registerable.rb +21 -0
  19. data/lib/vedeu/repositories/repositories/borders.rb +2 -1
  20. data/lib/vedeu/repositories/repositories/buffers.rb +2 -1
  21. data/lib/vedeu/repositories/repositories/cursors.rb +1 -1
  22. data/lib/vedeu/repositories/repositories/events_repository.rb +1 -1
  23. data/lib/vedeu/repositories/repositories/geometries.rb +2 -1
  24. data/lib/vedeu/repositories/repositories/groups.rb +1 -1
  25. data/lib/vedeu/repositories/repositories/interfaces_repository.rb +2 -1
  26. data/lib/vedeu/repositories/repositories/keymaps.rb +1 -1
  27. data/lib/vedeu/repositories/repositories/menus.rb +1 -1
  28. data/lib/vedeu/repositories/repository.rb +1 -10
  29. data/lib/vedeu/support/log.rb +27 -13
  30. data/lib/vedeu/support/terminal.rb +1 -1
  31. data/lib/vedeu/support/timer.rb +11 -4
  32. data/test/lib/vedeu/cursor/move_test.rb +9 -7
  33. data/test/lib/vedeu/geometry/coordinate_test.rb +29 -21
  34. data/test/lib/vedeu/geometry/geometry_test.rb +14 -2
  35. data/test/lib/vedeu/repositories/collections/all_test.rb +71 -0
  36. data/vedeu.gemspec +2 -5
  37. metadata +6 -22
  38. data/lib/vedeu/repositories/collections/chars.rb +0 -8
  39. data/lib/vedeu/repositories/collections/events.rb +0 -8
  40. data/lib/vedeu/repositories/collections/interfaces.rb +0 -8
  41. data/lib/vedeu/repositories/collections/keys.rb +0 -8
  42. data/lib/vedeu/repositories/collections/lines.rb +0 -8
  43. data/lib/vedeu/repositories/collections/streams.rb +0 -8
  44. data/test/lib/vedeu/repositories/collections/chars_test.rb +0 -16
  45. data/test/lib/vedeu/repositories/collections/events_test.rb +0 -16
  46. data/test/lib/vedeu/repositories/collections/interfaces_test.rb +0 -16
  47. data/test/lib/vedeu/repositories/collections/keys_test.rb +0 -16
  48. data/test/lib/vedeu/repositories/collections/lines_test.rb +0 -16
  49. data/test/lib/vedeu/repositories/collections/streams_test.rb +0 -16
@@ -0,0 +1,71 @@
1
+ require 'test_helper'
2
+
3
+ module Vedeu
4
+
5
+ describe Chars do
6
+
7
+ let(:described) { Vedeu::Chars }
8
+ let(:instance) { described.new }
9
+
10
+ describe '#initialize' do
11
+ it { instance.must_be_instance_of(described) }
12
+ end
13
+
14
+ end # Chars
15
+
16
+ describe Events do
17
+
18
+ let(:described) { Vedeu::Events }
19
+ let(:instance) { described.new }
20
+
21
+ describe '#initialize' do
22
+ it { instance.must_be_instance_of(described) }
23
+ end
24
+
25
+ end # Events
26
+
27
+ describe Interfaces do
28
+
29
+ let(:described) { Vedeu::Interfaces }
30
+ let(:instance) { described.new }
31
+
32
+ describe '#initialize' do
33
+ it { instance.must_be_instance_of(described) }
34
+ end
35
+
36
+ end # Interfaces
37
+
38
+ describe Keys do
39
+
40
+ let(:described) { Vedeu::Keys }
41
+ let(:instance) { described.new }
42
+
43
+ describe '#initialize' do
44
+ it { instance.must_be_instance_of(described) }
45
+ end
46
+
47
+ end # Keys
48
+
49
+ describe Lines do
50
+
51
+ let(:described) { Vedeu::Lines }
52
+ let(:instance) { described.new }
53
+
54
+ describe '#initialize' do
55
+ it { instance.must_be_instance_of(described) }
56
+ end
57
+
58
+ end # Lines
59
+
60
+ describe Streams do
61
+
62
+ let(:described) { Vedeu::Streams }
63
+ let(:instance) { described.new }
64
+
65
+ describe '#initialize' do
66
+ it { instance.must_be_instance_of(described) }
67
+ end
68
+
69
+ end # Streams
70
+
71
+ end # Vedeu
data/vedeu.gemspec CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = 'vedeu'
7
- spec.version = '0.4.23'
7
+ spec.version = '0.4.24'
8
8
  spec.authors = ['Gavin Laking']
9
9
  spec.email = ['gavinlaking@gmail.com']
10
10
  spec.summary = 'A terminal case of wonderland.'
@@ -18,15 +18,12 @@ Gem::Specification.new do |spec|
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ['lib']
20
20
 
21
- # spec.add_development_dependency 'aruba', '0.6.2'
22
21
  spec.add_development_dependency 'bundler', '~> 1.8'
23
- # spec.add_development_dependency 'cucumber', '2.0.0'
24
22
  spec.add_development_dependency 'guard', '2.12.5'
25
23
  spec.add_development_dependency 'guard-bundler', '2.1.0'
26
- # spec.add_development_dependency 'guard-cucumber', '1.6.0'
27
24
  spec.add_development_dependency 'guard-minitest', '2.4.4'
28
25
  spec.add_development_dependency 'inch', '0.6.2'
29
- spec.add_development_dependency 'minitest', '5.6.1'
26
+ spec.add_development_dependency 'minitest', '5.7.0'
30
27
  spec.add_development_dependency 'minitest-reporters', '1.0.16'
31
28
  spec.add_development_dependency 'mocha', '1.1.0'
32
29
  spec.add_development_dependency 'pry', '0.10.1'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vedeu
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.23
4
+ version: 0.4.24
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gavin Laking
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-25 00:00:00.000000000 Z
11
+ date: 2015-06-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -86,14 +86,14 @@ dependencies:
86
86
  requirements:
87
87
  - - '='
88
88
  - !ruby/object:Gem::Version
89
- version: 5.6.1
89
+ version: 5.7.0
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - '='
95
95
  - !ruby/object:Gem::Version
96
- version: 5.6.1
96
+ version: 5.7.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: minitest-reporters
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -405,12 +405,6 @@ files:
405
405
  - lib/vedeu/repositories/all.rb
406
406
  - lib/vedeu/repositories/collection.rb
407
407
  - lib/vedeu/repositories/collections/all.rb
408
- - lib/vedeu/repositories/collections/chars.rb
409
- - lib/vedeu/repositories/collections/events.rb
410
- - lib/vedeu/repositories/collections/interfaces.rb
411
- - lib/vedeu/repositories/collections/keys.rb
412
- - lib/vedeu/repositories/collections/lines.rb
413
- - lib/vedeu/repositories/collections/streams.rb
414
408
  - lib/vedeu/repositories/model.rb
415
409
  - lib/vedeu/repositories/registerable.rb
416
410
  - lib/vedeu/repositories/repositories/all.rb
@@ -531,12 +525,7 @@ files:
531
525
  - test/lib/vedeu/output/virtual_terminal_test.rb
532
526
  - test/lib/vedeu/output/wordwrap_test.rb
533
527
  - test/lib/vedeu/repositories/collection_test.rb
534
- - test/lib/vedeu/repositories/collections/chars_test.rb
535
- - test/lib/vedeu/repositories/collections/events_test.rb
536
- - test/lib/vedeu/repositories/collections/interfaces_test.rb
537
- - test/lib/vedeu/repositories/collections/keys_test.rb
538
- - test/lib/vedeu/repositories/collections/lines_test.rb
539
- - test/lib/vedeu/repositories/collections/streams_test.rb
528
+ - test/lib/vedeu/repositories/collections/all_test.rb
540
529
  - test/lib/vedeu/repositories/model_test.rb
541
530
  - test/lib/vedeu/repositories/registerable_test.rb
542
531
  - test/lib/vedeu/repositories/repositories/background_colours_test.rb
@@ -686,12 +675,7 @@ test_files:
686
675
  - test/lib/vedeu/output/virtual_terminal_test.rb
687
676
  - test/lib/vedeu/output/wordwrap_test.rb
688
677
  - test/lib/vedeu/repositories/collection_test.rb
689
- - test/lib/vedeu/repositories/collections/chars_test.rb
690
- - test/lib/vedeu/repositories/collections/events_test.rb
691
- - test/lib/vedeu/repositories/collections/interfaces_test.rb
692
- - test/lib/vedeu/repositories/collections/keys_test.rb
693
- - test/lib/vedeu/repositories/collections/lines_test.rb
694
- - test/lib/vedeu/repositories/collections/streams_test.rb
678
+ - test/lib/vedeu/repositories/collections/all_test.rb
695
679
  - test/lib/vedeu/repositories/model_test.rb
696
680
  - test/lib/vedeu/repositories/registerable_test.rb
697
681
  - test/lib/vedeu/repositories/repositories/background_colours_test.rb
@@ -1,8 +0,0 @@
1
- module Vedeu
2
-
3
- # A collection of {Vedeu::Char} instances.
4
- class Chars < Vedeu::Collection
5
-
6
- end # Chars
7
-
8
- end # Vedeu
@@ -1,8 +0,0 @@
1
- module Vedeu
2
-
3
- # A collection of {Vedeu::Event} instances.
4
- class Events < Vedeu::Collection
5
-
6
- end # Events
7
-
8
- end # Vedeu
@@ -1,8 +0,0 @@
1
- module Vedeu
2
-
3
- # A collection of {Vedeu::Interface} instances.
4
- class Interfaces < Vedeu::Collection
5
-
6
- end # Interfaces
7
-
8
- end # Vedeu
@@ -1,8 +0,0 @@
1
- module Vedeu
2
-
3
- # A collection of {Vedeu::Key} instances.
4
- class Keys < Vedeu::Collection
5
-
6
- end # Keys
7
-
8
- end # Vedeu
@@ -1,8 +0,0 @@
1
- module Vedeu
2
-
3
- # A collection of {Vedeu::Line} instances.
4
- class Lines < Vedeu::Collection
5
-
6
- end # Lines
7
-
8
- end # Vedeu
@@ -1,8 +0,0 @@
1
- module Vedeu
2
-
3
- # A collection of {Vedeu::Stream} instances.
4
- class Streams < Vedeu::Collection
5
-
6
- end # Streams
7
-
8
- end # Vedeu
@@ -1,16 +0,0 @@
1
- require 'test_helper'
2
-
3
- module Vedeu
4
-
5
- describe Chars do
6
-
7
- let(:described) { Vedeu::Chars }
8
- let(:instance) { described.new }
9
-
10
- describe '#initialize' do
11
- it { instance.must_be_instance_of(described) }
12
- end
13
-
14
- end # Chars
15
-
16
- end # Vedeu
@@ -1,16 +0,0 @@
1
- require 'test_helper'
2
-
3
- module Vedeu
4
-
5
- describe Events do
6
-
7
- let(:described) { Vedeu::Events }
8
- let(:instance) { described.new }
9
-
10
- describe '#initialize' do
11
- it { instance.must_be_instance_of(described) }
12
- end
13
-
14
- end # Events
15
-
16
- end # Vedeu
@@ -1,16 +0,0 @@
1
- require 'test_helper'
2
-
3
- module Vedeu
4
-
5
- describe Interfaces do
6
-
7
- let(:described) { Vedeu::Interfaces }
8
- let(:instance) { described.new }
9
-
10
- describe '#initialize' do
11
- it { instance.must_be_instance_of(described) }
12
- end
13
-
14
- end # Interfaces
15
-
16
- end # Vedeu
@@ -1,16 +0,0 @@
1
- require 'test_helper'
2
-
3
- module Vedeu
4
-
5
- describe Keys do
6
-
7
- let(:described) { Vedeu::Keys }
8
- let(:instance) { described.new }
9
-
10
- describe '#initialize' do
11
- it { instance.must_be_instance_of(described) }
12
- end
13
-
14
- end # Keys
15
-
16
- end # Vedeu
@@ -1,16 +0,0 @@
1
- require 'test_helper'
2
-
3
- module Vedeu
4
-
5
- describe Lines do
6
-
7
- let(:described) { Vedeu::Lines }
8
- let(:instance) { described.new }
9
-
10
- describe '#initialize' do
11
- it { instance.must_be_instance_of(described) }
12
- end
13
-
14
- end # Lines
15
-
16
- end # Vedeu
@@ -1,16 +0,0 @@
1
- require 'test_helper'
2
-
3
- module Vedeu
4
-
5
- describe Streams do
6
-
7
- let(:described) { Vedeu::Streams }
8
- let(:instance) { described.new }
9
-
10
- describe '#initialize' do
11
- it { instance.must_be_instance_of(described) }
12
- end
13
-
14
- end # Streams
15
-
16
- end # Vedeu