Skip to content

Commit

Permalink
[ISV-1344] As a partner, the hosted pipeline won't re-test my operato…
Browse files Browse the repository at this point in the history
…r if only project settings are changed (#164)

* [ISV-1344] Preflight tests are only skipped if the result aren't passed.

* Add log for the preflight results

* Enclose the log into else condition

Co-authored-by: haripate <>
  • Loading branch information
haripate authored Nov 11, 2021
1 parent fe0ce90 commit d5cf0b8
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ spec:
cat test_result_id | tee $(results.test_result_id.path)
- name: indicate-if-results-exists
image: registry.access.redhat.com/ubi8-minimal@sha256:54ef2173bba7384dc7609e8affbae1c36f8a3ec137cacc0866116d65dd4b9afe
image: "$(params.pipeline_image)"
workingDir: $(workspaces.results.path)
env:
- name: RESULTS_FILE
Expand All @@ -71,7 +71,13 @@ spec:
if [ -f $RESULTS_FILE ]; then
echo "Results exist"
echo -n "true" | tee $(results.preflight_results_exists.path)
CHECK_RESULTS=$(cat $RESULTS_FILE | jq -r '.passed')
if [ $CHECK_RESULTS = "false" ]; then
echo "Not all preflight tests passed."
else
echo "All preflight tests passed successfully."
fi
echo -n "$CHECK_RESULTS" | tee $(results.preflight_results_exists.path)
echo -n "$RESULTS_FILE" | tee $(results.preflight_results.path)
else
echo "Results do not exist"
Expand Down

0 comments on commit d5cf0b8

Please sign in to comment.