tests: quote .[] in shtest which can break syntax highlight (#3235)
This commit is contained in:
1 parent
562ffec869
commit
31dac287cc
1 file changed
+2
-2
+2
-2
@@ -140,10 +140,10 @@ cmp $d/out $d/expected
|
|||||||
|
|
||||||
# Regression test for --raw-output0
|
# Regression test for --raw-output0
|
||||||
printf "a\0b\0" > $d/expected
|
printf "a\0b\0" > $d/expected
|
||||||
printf '["a", "b"]' | $VALGRIND $Q $JQ --raw-output0 .[] > $d/out
|
printf '["a", "b"]' | $VALGRIND $Q $JQ --raw-output0 '.[]' > $d/out
|
||||||
cmp $d/out $d/expected
|
cmp $d/out $d/expected
|
||||||
printf "a\0" > $d/expected
|
printf "a\0" > $d/expected
|
||||||
if printf '["a", "c\\u0000d", "b"]' | $VALGRIND $Q $JQ --raw-output0 .[] > $d/out; then
|
if printf '["a", "c\\u0000d", "b"]' | $VALGRIND $Q $JQ --raw-output0 '.[]' > $d/out; then
|
||||||
echo "Should exit error on string containing NUL with --raw-output0" 1>&2
|
echo "Should exit error on string containing NUL with --raw-output0" 1>&2
|
||||||
exit 1
|
exit 1
|
||||||
elif [ $? -ne 5 ]; then
|
elif [ $? -ne 5 ]; then
|
||||||
|
|||||||
Reference in new issue
Block a user