Skip to content

Commit 90f958f

Browse files
authored
ci: Skip optional E2E tests on release branches (#14424)
Optional tests should not block releases. There are two groups of optional tests: 1. Canary type tests 2. Tests that send data to sentry IMHO both of these can be skipped on release branches, as failure in either of them should not affect the release. They will (for now) still run on develop, we can revisit this if we want.
1 parent 6535500 commit 90f958f

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/build.yml

+6-2
Original file line numberDiff line numberDiff line change
@@ -795,7 +795,8 @@ jobs:
795795
# - The build job was successful, not skipped
796796
# - AND if the profiling node bindings were either successful or skipped
797797
if: |
798-
always() && needs.job_build.result == 'success' &&
798+
always() &&
799+
needs.job_build.result == 'success' &&
799800
(needs.job_compile_bindings_profiling_node.result == 'success' || needs.job_compile_bindings_profiling_node.result == 'skipped')
800801
needs: [job_get_metadata, job_build, job_compile_bindings_profiling_node]
801802
runs-on: ubuntu-20.04-large-js
@@ -981,13 +982,16 @@ jobs:
981982
directory: dev-packages/e2e-tests
982983
token: ${{ secrets.CODECOV_TOKEN }}
983984

985+
# - We skip optional tests on release branches
984986
job_optional_e2e_tests:
985987
name: E2E ${{ matrix.label || matrix.test-application }} Test
986988
# We only run E2E tests for non-fork PRs because the E2E tests require secrets to work and they can't be accessed from forks
987989
# We need to add the `always()` check here because the previous step has this as well :(
988990
# See: https://github.com/actions/runner/issues/2205
989991
if:
990-
always() && needs.job_e2e_prepare.result == 'success' &&
992+
always() &&
993+
needs.job_get_metadata.outputs.is_release != 'true' &&
994+
needs.job_e2e_prepare.result == 'success' &&
991995
needs.job_e2e_prepare.outputs.matrix-optional != '{"include":[]}' &&
992996
(github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) &&
993997
github.actor != 'dependabot[bot]'

0 commit comments

Comments
 (0)