Skip to content

Commit 7064d1b

Browse files
authored
chore: Fix send_notification in Test Suite (#3792)
1 parent 4bbbaa6 commit 7064d1b

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

.github/workflows/acceptance-tests-runner.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1330,7 +1330,7 @@ jobs:
13301330

13311331
slack-notification-stream:
13321332
needs: [stream]
1333-
if: ${{ !cancelled() && needs.stream.result == 'failure' && inputs.send_notification == true }}
1333+
if: ${{ !cancelled() && needs.stream.result == 'failure' && !contains(github.event.inputs.send_notification, 'false') }}
13341334
runs-on: ubuntu-latest
13351335
permissions: {}
13361336
steps:

.github/workflows/acceptance-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ jobs:
127127
test_name: ${{ inputs.test_name }}
128128
reduced_tests: ${{ inputs.reduced_tests || false }}
129129
use_sa: ${{ inputs.use_sa || false }}
130-
send_notification: ${{ inputs.send_notification || false }}
130+
send_notification: ${{ !contains(github.event.inputs.send_notification, 'false') }}
131131
aws_region_federation: ${{ vars.AWS_REGION_FEDERATION }}
132132
mongodb_atlas_org_id: ${{ inputs.atlas_cloud_env == 'qa' && vars.MONGODB_ATLAS_ORG_ID_CLOUD_QA || vars.MONGODB_ATLAS_ORG_ID_CLOUD_DEV }}
133133
mongodb_atlas_base_url: ${{ inputs.atlas_cloud_env == 'qa' && vars.MONGODB_ATLAS_BASE_URL_QA || vars.MONGODB_ATLAS_BASE_URL }}

.github/workflows/test-suite.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,9 @@ jobs:
8787
provider_version: ${{ matrix.provider_version }}
8888
atlas_cloud_env: ${{ inputs.atlas_cloud_env || needs.variables.outputs.is_sun == 'true' && 'qa' || '' }} # Run against QA on Sundays
8989
use_sa: ${{ needs.variables.outputs.use_sa == 'true' }}
90-
send_notification: ${{ inputs.send_notification || false }}
90+
# This expression is true if unset (scheduled workflow) and works with boolean and string (GHA params are passed as strings)
91+
send_notification: ${{ !contains(github.event.inputs.send_notification, 'false') }}
92+
9193
clean-after:
9294
needs: tests
9395
if: ${{ !cancelled() }}

0 commit comments

Comments
 (0)