Skip to content

Commit

Permalink
fix: Decrease verbosity
Browse files Browse the repository at this point in the history
  • Loading branch information
dadav committed Dec 30, 2024
1 parent 94a8258 commit c20d832
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions tests/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,20 @@ cp ../examples/values.yaml test_repo_example.yaml
cp ../examples/values.schema.json test_repo_example_expected.schema.json

for test_file in test_*.yaml; do
expected_file="${test_file%.yaml}_expected.schema.json"
generated_file="${test_file%.yaml}_generated.schema.json"
if ! ./helm-schema -f "$test_file" -o "$generated_file"; then
echo "❌: $test_file"
rc=1
continue
fi
echo "Testing $test_file"
if diff -y <(jq --sort-keys . "$generated_file") <(jq --sort-keys . "$expected_file"); then
echo "✅: $test_file"
else
echo "❌: $test_file"
rc=1
fi
expected_file="${test_file%.yaml}_expected.schema.json"
generated_file="${test_file%.yaml}_generated.schema.json"
if ! ./helm-schema -f "$test_file" -o "$generated_file"; then
echo "❌: $test_file"
rc=1
continue
fi
echo "Testing $test_file"
if diff -y --suppress-common-lines <(jq --sort-keys . "$generated_file") <(jq --sort-keys . "$expected_file"); then
echo "✅: $test_file"
else
echo "❌: $test_file"
rc=1
fi
done

exit "$rc"

0 comments on commit c20d832

Please sign in to comment.