Skip to content
This repository has been archived by the owner on Sep 26, 2024. It is now read-only.

Commit

Permalink
Update smoketests.yml - Mod to draft param (#7217)
Browse files Browse the repository at this point in the history
* Update smoketests.yml - Mod to draft param

The draft param wasn't being interpretted correctly.

* Update smoketests.yml
  • Loading branch information
markodonnell-deriv authored Mar 1, 2024
1 parent 9a5a94c commit 4c35be5
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/smoketests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ jobs:
echo "branch_name=$(cat ./pr/BRANCHNAME)" >> $GITHUB_OUTPUT
echo "user_name=$(cat ./pr/USERNAME)" >> $GITHUB_OUTPUT
echo "draft=$(cat ./pr/DRAFT)" >> $GITHUB_OUTPUT
- name: pr_info_debug 🔍
run: |
echo "PR Draft value ={{ $steps.pr_information.outputs.draft }}--"
- name: Checkout external repository with Cypress tests
uses: actions/checkout@v4
Expand All @@ -49,7 +53,7 @@ jobs:

- name: Cypress run
# Uses the official Cypress GitHub action https://github.com/cypress-io/github-action
if: (!steps.pr_information.outputs.draft)
if: "contains(steps.pr_information.outputs.draft, 'false')"
uses: cypress-io/github-action@v6
with:
# Records to Cypress Cloud
Expand All @@ -72,7 +76,7 @@ jobs:

- name: Set comments message
id: set_msg
if: always() && (!steps.pr_information.outputs.draft)
if: always() && contains(steps.pr_information.outputs.draft, 'false')
run: |
# Using shell script to conditionally set the message
if [[ "${{ job.status }}" == "success" ]]; then
Expand All @@ -82,7 +86,7 @@ jobs:
fi
- name: Leave comment
if: always() && (!steps.pr_information.outputs.draft)
if: always() && contains(steps.pr_information.outputs.draft, 'false')
uses: marocchino/sticky-pull-request-comment@v2
with:
header: Smoke tests status update
Expand Down

0 comments on commit 4c35be5

Please sign in to comment.