Skip to content

Commit

Permalink
build matrix??
Browse files Browse the repository at this point in the history
  • Loading branch information
mydea committed Jul 11, 2023
1 parent 16afed9 commit 1f9527a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
22 changes: 18 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -730,7 +730,7 @@ jobs:
yarn test:integration:ci
job_e2e_tests:
name: E2E Test ${{ matrix.test-application }}
name: E2E Test ${{ matrix.test-application }}) ${{ matrix.build-command || '' }}
# 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
# Dependabot PRs sadly also don't have access to secrets, so we skip them as well
if:
Expand All @@ -743,6 +743,11 @@ jobs:
fail-fast: false
matrix:
test-application: ['node-express-app', 'create-react-app']
build-command:
- false
include:
- test-application: 'create-react-app'
build-command: [false, 'test:build-ts3.8']

steps:
- name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }})
Expand Down Expand Up @@ -780,16 +785,25 @@ jobs:
E2E_TEST_SENTRY_ORG_SLUG: 'sentry-javascript-sdks'
E2E_TEST_SENTRY_TEST_PROJECT: 'sentry-javascript-e2e-tests'

- name: Build E2E app
env:
E2E_TEST_AUTH_TOKEN: ${{ secrets.E2E_TEST_AUTH_TOKEN }}
E2E_TEST_DSN: ${{ secrets.E2E_TEST_DSN }}
E2E_TEST_SENTRY_ORG_SLUG: 'sentry-javascript-sdks'
E2E_TEST_SENTRY_TEST_PROJECT: 'sentry-javascript-e2e-tests'
working-directory: packages/e2e-tests/test-applications/${{ matrix.test-application }}
timeout-minutes: 5
run: ${{ matrix.build-command || 'yarn test:build' }}

- name: Run E2E test
env:
E2E_TEST_AUTH_TOKEN: ${{ secrets.E2E_TEST_AUTH_TOKEN }}
E2E_TEST_DSN: ${{ secrets.E2E_TEST_DSN }}
E2E_TEST_SENTRY_ORG_SLUG: 'sentry-javascript-sdks'
E2E_TEST_SENTRY_TEST_PROJECT: 'sentry-javascript-e2e-tests'
working-directory: packages/e2e-tests/test-applications/${{ matrix.test-application }}
run: |
yarn test:build
yarn test:assert
timeout-minutes: 5
run: yarn test:assert

job_required_tests:
name: All required tests passed or skipped
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Sentry.init({
});

const app = express();
const port = 8000;
const port = 9000;

app.use(Sentry.Handlers.requestHandler());
app.use(Sentry.Handlers.tracingHandler());
Expand Down

0 comments on commit 1f9527a

Please sign in to comment.