File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -14,12 +14,14 @@ module Spring
14
14
module Client
15
15
COMMANDS = {
16
16
"help" => Client ::Help ,
17
+ "-h" => Client ::Help ,
18
+ "--help" => Client ::Help ,
17
19
"binstub" => Client ::Binstub ,
18
20
"stop" => Client ::Stop ,
19
21
"status" => Client ::Status ,
20
22
"rails" => Client ::Rails ,
21
23
"-v" => Client ::Version ,
22
- "--version" => Client ::Version
24
+ "--version" => Client ::Version ,
23
25
}
24
26
25
27
def self . run ( args )
Original file line number Diff line number Diff line change @@ -84,6 +84,14 @@ def without_gem(name)
84
84
85
85
test "help message when called without arguments" do
86
86
assert_success "bin/spring" , stdout : 'Usage: spring COMMAND [ARGS]'
87
+ assert app . spring_env . server_running?
88
+ end
89
+
90
+ test "shows help" do
91
+ assert_success "bin/spring help" , stdout : 'Usage: spring COMMAND [ARGS]'
92
+ assert_success "bin/spring -h" , stdout : 'Usage: spring COMMAND [ARGS]'
93
+ assert_success "bin/spring --help" , stdout : 'Usage: spring COMMAND [ARGS]'
94
+ refute app . spring_env . server_running?
87
95
end
88
96
89
97
test "test changes are picked up" do
You can’t perform that action at this time.
0 commit comments