Skip to content

Commit 78642e9

Browse files
authored
feat: run-e2e-tests branch-out in-memory integ tests (#1451)
1 parent b6b1b68 commit 78642e9

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

.github/workflows/run-e2e-tests.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1275,6 +1275,7 @@ jobs:
12751275
contents: read
12761276
env:
12771277
TEST_ID: ${{ matrix.tests.id_sanitized || matrix.tests.id }}
1278+
QUARANTINE: ${{ inputs.quarantine }}
12781279
steps:
12791280
- name: Enable S3 Cache for Self-Hosted Runners
12801281
# these env vars are set (and exposed) when it is a self-hosted runner with extras=s3-cache
@@ -1321,6 +1322,8 @@ jobs:
13211322
id: run_tests
13221323
timeout-minutes: ${{ matrix.tests.timeout_minutes || inputs.test-timeout-minutes }}
13231324
uses: smartcontractkit/.github/actions/ctf-run-tests@ctf-run-tests/0.11.0
1325+
# jankiness because: github.com/actions/runner/issues/1492 + github.com/actions/runner/issues/2418
1326+
continue-on-error: ${{ fromJSON(env.QUARANTINE) }}
13241327
env:
13251328
RUN_QUARANTINED_TESTS: "true" # always run quarantined tests in CI
13261329
with:
@@ -1349,6 +1352,32 @@ jobs:
13491352
sui_cli_version: ${{ matrix.tests.sui_cli_version }}
13501353
setup_db: "true"
13511354

1355+
- name: Enforce /tmp/junit.xml exists (quarantine only)
1356+
id: check-junit
1357+
# This fails the job if there is no junit report and the test step did not succeed.
1358+
# If there is no report then the branch-out-upload step will not be able to properly
1359+
# determine the test result, so we need to fail the job here instead.
1360+
if: ${{ !cancelled() && inputs.quarantine == 'true' }}
1361+
shell: bash
1362+
env:
1363+
RESULT: ${{ steps.run_tests.outcome }}
1364+
run: |
1365+
if [ ! -f /tmp/junit.xml ]; then
1366+
echo "::error::Junit report not found, and run_tests outcome is $RESULT. Failing the job."
1367+
exit 1
1368+
fi
1369+
1370+
- name: Run branch-out-upload (quarantine only)
1371+
if: ${{ !cancelled() && inputs.quarantine == 'true' }}
1372+
uses: smartcontractkit/.github/actions/branch-out-upload@branch-out-upload/0.1.0
1373+
with:
1374+
junit-file-path: "/tmp/junit.xml"
1375+
trunk-org-slug: chainlink
1376+
trunk-token: ${{ secrets.TRUNK_API_KEY }}
1377+
trunk-previous-step-outcome: ${{ steps.run_tests.outcome }}
1378+
trunk-job-url: ${{ format('https://github.com/{0}/actions/runs/{1}/job/{2}/attempts/{3}', github.repository, github.run_id, job.check_run_id, github.run_attempt) }}
1379+
trunk-upload-only: "false"
1380+
13521381
after_tests:
13531382
needs: [load-test-configurations, run-docker-tests, run-k8s-runner-tests, run-in-memory-tests]
13541383
if: always()

0 commit comments

Comments
 (0)