fix: update part of e2e tests

Signed-off-by: AhmedGrati <ahmedgrati1999@gmail.com>
This commit is contained in:
AhmedGrati
2023-10-11 20:09:07 +01:00
parent 09dc978e8e
commit 115f3862fc
49 changed files with 37 additions and 332 deletions
+1 -1
View File
@@ -100,7 +100,7 @@ function convert::match_output() {
convert::run_cmd $cmd
exit_status=$?
if [ $exit_status -ne 0 ]; then FAIL_MSGS=$FAIL_MSGS"exit status: $exit_status\n"; return $exit_status; fi
match=$(diff <(yq ea '[.] | sort_by(.metadata.name) | .[] | splitDoc' $expected_output) <(yq ea '[.] | sort_by(.metadata.name) | .[] | splitDoc' $TEMP_STDOUT))
match=$(diff <(yq -P 'sort_keys(..)' -o=props $expected_output) <(yq -P 'sort_keys(..)' -o=props $TEMP_STDOUT))
echo "$match" > /tmp/diff
if [ "$match" == "" ]; then SUCCESS_MSGS=$SUCCESS_MSGS"converted output matches\n"; return 0;
else FAIL_MSGS=$FAIL_MSGS"converted output does not match\n"; cat /tmp/diff; rm /tmp/diff; return 1;