File tree Expand file tree Collapse file tree 3 files changed +24
-0
lines changed Expand file tree Collapse file tree 3 files changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -39,6 +39,10 @@ bash_object.traverse-get() {
39
39
return
40
40
fi
41
41
42
+ if [ " $flag_as_what " = ' as-ref' ]; then
43
+ bash_object.util.die ' ERROR_ARGUMENTS_INVALID' " --as-ref not implemented"
44
+ fi
45
+
42
46
# Ensure correct number of arguments have been passed
43
47
if (( ${# args[@]} != 3 )) ; then
44
48
bash_object.util.die ' ERROR_ARGUMENTS_INVALID' " Expected '3' arguments, but received '${# args[@]} '"
Original file line number Diff line number Diff line change @@ -37,6 +37,10 @@ bash_object.traverse-set() {
37
37
return
38
38
fi
39
39
40
+ if [ " $flag_pass_by_what " = ' by-value' ]; then
41
+ bash_object.util.die ' ERROR_ARGUMENTS_INVALID' " --by-value not implemented"
42
+ fi
43
+
40
44
local final_value_type root_object_name filter final_value
41
45
# `set -u` compat
42
46
if [ -n " ${args[0]+x} " ]; then
Original file line number Diff line number Diff line change @@ -19,6 +19,14 @@ load './util/init.sh'
19
19
assert_line -p " Flags '--as-ref' and '--as-value' are mutually exclusive"
20
20
}
21
21
22
+ @test " error on unimplemented --as-ref" {
23
+ run bobject get-string --as-ref
24
+
25
+ assert_failure
26
+ assert_line -p ' ERROR_ARGUMENTS_INVALID'
27
+ assert_line -p " --as-ref not implemented"
28
+ }
29
+
22
30
# set
23
31
@test " set errors on missing flags" {
24
32
run bobject set-string
@@ -35,3 +43,11 @@ load './util/init.sh'
35
43
assert_line -p ' ERROR_ARGUMENTS_INVALID'
36
44
assert_line -p " Flags '--by-ref' and '--by-value' are mutually exclusive"
37
45
}
46
+
47
+ @test " error on unimplemented --by-value" {
48
+ run bobject set-string --by-value
49
+
50
+ assert_failure
51
+ assert_line -p ' ERROR_ARGUMENTS_INVALID'
52
+ assert_line -p " --by-value not implemented"
53
+ }
You can’t perform that action at this time.
0 commit comments