vedeu 0.4.43 → 0.4.44
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Dockerfile +1 -1
- data/bin/vedeu +19 -0
- data/lib/vedeu.rb +0 -34
- data/lib/vedeu/all.rb +4 -1
- data/lib/vedeu/application/application_view.rb +9 -9
- data/lib/vedeu/application/controller.rb +6 -5
- data/lib/vedeu/application/helper.rb +3 -16
- data/lib/vedeu/application/view.rb +3 -16
- data/lib/vedeu/bindings/all.rb +5 -0
- data/lib/vedeu/bindings/bindings.rb +115 -0
- data/lib/vedeu/bindings/drb.rb +45 -0
- data/lib/vedeu/bindings/menus.rb +53 -0
- data/lib/vedeu/bindings/movement.rb +76 -0
- data/lib/vedeu/bindings/visibility.rb +53 -0
- data/lib/vedeu/buffers/buffer.rb +2 -0
- data/lib/vedeu/cli/generator/templates/application/app/controllers/name.erb +2 -2
- data/lib/vedeu/cli/generator/templates/application/app/helpers/name.erb +2 -0
- data/lib/vedeu/cli/generator/templates/application/config/configuration.erb +3 -0
- data/lib/vedeu/cli/generator/view.rb +0 -5
- data/lib/vedeu/cli/main.rb +12 -0
- data/lib/vedeu/cursor/reposition.rb +4 -4
- data/lib/vedeu/dsl/interface.rb +0 -27
- data/lib/vedeu/exceptions.rb +65 -0
- data/lib/vedeu/geometry/geometry.rb +2 -2
- data/lib/vedeu/geometry/grid.rb +2 -2
- data/lib/vedeu/input/input.rb +34 -28
- data/lib/vedeu/null/geometry.rb +2 -2
- data/lib/vedeu/output/colour.rb +0 -2
- data/lib/vedeu/output/esc.rb +7 -1
- data/lib/vedeu/output/render_border.rb +5 -0
- data/lib/vedeu/output/renderers/json.rb +7 -2
- data/lib/vedeu/support/terminal.rb +1 -1
- data/lib/vedeu/version.rb +1 -1
- data/test/lib/vedeu/application/controller_test.rb +0 -4
- data/test/lib/vedeu/application/helper_test.rb +0 -8
- data/test/lib/vedeu/application/view_test.rb +0 -8
- data/test/lib/vedeu/bindings/bindings_test.rb +43 -0
- data/test/lib/vedeu/bindings/drb_test.rb +23 -0
- data/test/lib/vedeu/bindings/menus_test.rb +26 -0
- data/test/lib/vedeu/bindings/movement_test.rb +28 -0
- data/test/lib/vedeu/bindings/visibility_test.rb +27 -0
- data/test/lib/vedeu/buffers/buffer_test.rb +73 -38
- data/test/lib/vedeu/cli/main_test.rb +47 -0
- data/test/lib/vedeu/dsl/interface_test.rb +4 -7
- data/test/lib/vedeu/exceptions_test.rb +5 -0
- data/test/lib/vedeu/input/input_test.rb +9 -0
- data/test/lib/vedeu/output/esc_test.rb +4 -1
- metadata +21 -5
- data/lib/vedeu/bindings.rb +0 -275
- data/test/lib/vedeu/bindings_test.rb +0 -88
@@ -1,88 +0,0 @@
|
|
1
|
-
require 'test_helper'
|
2
|
-
|
3
|
-
module Vedeu
|
4
|
-
|
5
|
-
describe Bindings do
|
6
|
-
|
7
|
-
context 'the system events needed by Vedeu to run are defined' do
|
8
|
-
it { Vedeu.events.registered?(:_clear_).must_equal(true) }
|
9
|
-
it { Vedeu.events.registered?(:_clear_group_).must_equal(true) }
|
10
|
-
it { Vedeu.events.registered?(:_cleanup_).must_equal(true) }
|
11
|
-
it { Vedeu.events.registered?(:_command_).must_equal(true) }
|
12
|
-
it { Vedeu.events.registered?(:_exit_).must_equal(true) }
|
13
|
-
it { Vedeu.events.registered?(:_hide_group_).must_equal(true) }
|
14
|
-
it { Vedeu.events.registered?(:_initialize_).must_equal(true) }
|
15
|
-
it { Vedeu.events.registered?(:_keypress_).must_equal(true) }
|
16
|
-
it { Vedeu.events.registered?(:_log_).must_equal(true) }
|
17
|
-
it { Vedeu.events.registered?(:_mode_switch_).must_equal(true) }
|
18
|
-
it { Vedeu.events.registered?(:_refresh_).must_equal(true) }
|
19
|
-
it { Vedeu.events.registered?(:_refresh_cursor_).must_equal(true) }
|
20
|
-
it { Vedeu.events.registered?(:_refresh_group_).must_equal(true) }
|
21
|
-
it { Vedeu.events.registered?(:_resize_).must_equal(true) }
|
22
|
-
it { Vedeu.events.registered?(:_show_group_).must_equal(true) }
|
23
|
-
end
|
24
|
-
|
25
|
-
context 'the cursor specific events are defined' do
|
26
|
-
it { Vedeu.events.registered?(:_cursor_hide_).must_equal(true) }
|
27
|
-
it { Vedeu.events.registered?(:_cursor_show_).must_equal(true) }
|
28
|
-
it { Vedeu.events.registered?(:_hide_cursor_).must_equal(true) }
|
29
|
-
it { Vedeu.events.registered?(:_show_cursor_).must_equal(true) }
|
30
|
-
it { Vedeu.events.registered?(:_cursor_down_).must_equal(true) }
|
31
|
-
it { Vedeu.events.registered?(:_cursor_left_).must_equal(true) }
|
32
|
-
it { Vedeu.events.registered?(:_cursor_right_).must_equal(true) }
|
33
|
-
it { Vedeu.events.registered?(:_cursor_up_).must_equal(true) }
|
34
|
-
it { Vedeu.events.registered?(:_cursor_origin_).must_equal(true) }
|
35
|
-
it { Vedeu.events.registered?(:_cursor_position_).must_equal(true) }
|
36
|
-
it { Vedeu.events.registered?(:_cursor_reposition_).must_equal(true) }
|
37
|
-
it { Vedeu.events.registered?(:_cursor_reset_).must_equal(true) }
|
38
|
-
end
|
39
|
-
|
40
|
-
context 'the geometry specific events are defined' do
|
41
|
-
it { Vedeu.events.registered?(:_geometry_down_).must_equal(true) }
|
42
|
-
it { Vedeu.events.registered?(:_geometry_left_).must_equal(true) }
|
43
|
-
it { Vedeu.events.registered?(:_geometry_right_).must_equal(true) }
|
44
|
-
it { Vedeu.events.registered?(:_geometry_up_).must_equal(true) }
|
45
|
-
it { Vedeu.events.registered?(:_maximise_).must_equal(true) }
|
46
|
-
it { Vedeu.events.registered?(:_unmaximise_).must_equal(true) }
|
47
|
-
end
|
48
|
-
|
49
|
-
context 'the drb specific events are defined' do
|
50
|
-
it { Vedeu.events.registered?(:_drb_input_).must_equal(true) }
|
51
|
-
it { Vedeu.events.registered?(:_drb_retrieve_output_).must_equal(true) }
|
52
|
-
it { Vedeu.events.registered?(:_drb_store_output_).must_equal(true) }
|
53
|
-
it { Vedeu.events.registered?(:_drb_restart_).must_equal(true) }
|
54
|
-
it { Vedeu.events.registered?(:_drb_start_).must_equal(true) }
|
55
|
-
it { Vedeu.events.registered?(:_drb_status_).must_equal(true) }
|
56
|
-
it { Vedeu.events.registered?(:_drb_stop_).must_equal(true) }
|
57
|
-
end
|
58
|
-
|
59
|
-
context 'the focus specific events are defined' do
|
60
|
-
it { Vedeu.events.registered?(:_focus_by_name_).must_equal(true) }
|
61
|
-
it { Vedeu.events.registered?(:_focus_next_).must_equal(true) }
|
62
|
-
it { Vedeu.events.registered?(:_focus_prev_).must_equal(true) }
|
63
|
-
end
|
64
|
-
|
65
|
-
context 'the menu specific events are defined' do
|
66
|
-
it { Vedeu.events.registered?(:_menu_bottom_).must_equal(true) }
|
67
|
-
it { Vedeu.events.registered?(:_menu_current_).must_equal(true) }
|
68
|
-
it { Vedeu.events.registered?(:_menu_deselect_).must_equal(true) }
|
69
|
-
it { Vedeu.events.registered?(:_menu_items_).must_equal(true) }
|
70
|
-
it { Vedeu.events.registered?(:_menu_next_).must_equal(true) }
|
71
|
-
it { Vedeu.events.registered?(:_menu_prev_).must_equal(true) }
|
72
|
-
it { Vedeu.events.registered?(:_menu_selected_).must_equal(true) }
|
73
|
-
it { Vedeu.events.registered?(:_menu_select_).must_equal(true) }
|
74
|
-
it { Vedeu.events.registered?(:_menu_top_).must_equal(true) }
|
75
|
-
it { Vedeu.events.registered?(:_menu_view_).must_equal(true) }
|
76
|
-
end
|
77
|
-
|
78
|
-
context 'the refresh event for all registered interfaces is defined' do
|
79
|
-
it { Vedeu.events.registered?(:_refresh_).must_equal(true) }
|
80
|
-
end
|
81
|
-
|
82
|
-
it { Vedeu.events.registered?(:_hide_interface_).must_equal(true) }
|
83
|
-
it { Vedeu.events.registered?(:_show_interface_).must_equal(true) }
|
84
|
-
it { Vedeu.events.registered?(:_toggle_interface_).must_equal(true) }
|
85
|
-
|
86
|
-
end # Bindings
|
87
|
-
|
88
|
-
end # Vedeu
|