File tree Expand file tree Collapse file tree 3 files changed +49
-3
lines changed
Expand file tree Collapse file tree 3 files changed +49
-3
lines changed Original file line number Diff line number Diff line change 2929 # - why? given we reuse preprod for R1.0 and R2.0, when IAM permission change across releases, then deployment fails
3030 # - constraint? make sure R2.0 IAM permissions are a superset of R1.0 IAM permissions
3131 # - what? deploy IAM from R2.0 as it is a superset and then R1.0 deployments will succeed as well
32- - name : " Checkout code "
32+ - name : " Checkout main branch "
3333 uses : actions/checkout@v5
3434 with :
3535 ref : ' main'
8080 # Download the required artefacts from AWS
8181 # ################################################
8282
83- - name : " Checkout code"
83+ - name : " Checkout target code"
8484 uses : actions/checkout@v5
8585 with :
8686 ref : ${{ inputs.tag_or_sha_to_deploy }}
Original file line number Diff line number Diff line change 1+ name : run-contract-tests
2+ description : " Run contract tests"
3+
4+ inputs :
5+ target_ref :
6+ description : " Target ref to run tests on"
7+ required : true
8+
9+ runs :
10+ using : " composite"
11+ steps :
12+ # ################################################
13+ # Run contract tests
14+ # ################################################
15+
16+ - name : " Checkout target code"
17+ uses : actions/checkout@v5
18+ with :
19+ ref : ${{ inputs.target_ref }}
20+ path : " code-for-contract-tests"
21+
22+ - name : " Cache node modules"
23+ uses : actions/cache@v4
24+ env :
25+ cache-name : cache-node-modules
26+ with :
27+ path : ~/.npm
28+ key : ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('./code-for-contract-tests/**/package-lock.json') }}
29+
30+ - name : " Install dependencies"
31+ shell : bash
32+ working-directory : " ./code-for-contract-tests"
33+ run : |
34+ npm ci --ignore-scripts
35+
36+ - name : " Run contract tests ${{inputs.environment}}"
37+ shell : bash
38+ working-directory : " ./code-for-contract-tests"
39+ run : |
40+ npm run contract
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ name: "CI/CD scheduled assurances WIP"
22
33on :
44 schedule :
5- - cron : ' 22 15 * * MON-FRI' # Runs at 09:30 UTC every weekday
5+ - cron : ' 30 9 * * MON-FRI' # Runs at 09:30 UTC every weekday
66 workflow_dispatch :
77 inputs :
88 release :
5353 secret_aws_iam_role : ${{ secrets.IAM_ROLE }}
5454 secret_aws_slack_channel_id : ${{ secrets.ALARMS_SLACK_CHANNEL_ID }}
5555
56+ - name : " Run contract tests (sandpit+mocked)"
57+ timeout-minutes : 10
58+ uses : ./.github/actions/run-contract-tests
59+ with :
60+ target_ref : ${{ steps.get-latest-tag-name.outputs.value }}
61+
5662 deploy-and-test-main :
5763 name : " Main Branch Assurance"
5864 runs-on : " ubuntu-latest"
You can’t perform that action at this time.
0 commit comments