Skip to content

Commit b9bb23e

Browse files
committed
test: cover stdin edge cases and fix shellcheck warnings-2
Signed-off-by: Vaibhav mittal <vaibhavmittal929@gmail.com>
1 parent dead00c commit b9bb23e

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

test/validate/pass_stdin.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,10 @@ echo '{"foo": "bar"}' | "$1" validate "$TMP/schema.json" -
2222
echo 'foo: bar' | "$1" validate "$TMP/schema.json" -
2323

2424
set +o errexit
25-
OUTPUT=$("$1" validate - "$TMP/schema.json" < "$TMP/schema.json" 2>&1)
25+
cat "$TMP/schema.json" > "$TMP/schema_stdin.json"
26+
27+
OUTPUT=$("$1" validate - "$TMP/schema.json" < "$TMP/schema_stdin.json" 2>&1)
28+
2629
EXIT_CODE=$?
2730
set -o errexit
2831

0 commit comments

Comments
 (0)