Skip to content

Commit

Permalink
Run tests in Firefox
Browse files Browse the repository at this point in the history
  • Loading branch information
jaril committed Sep 27, 2022
1 parent ffc0ee8 commit 0138854
Showing 1 changed file with 77 additions and 0 deletions.
77 changes: 77 additions & 0 deletions .github/workflows/build_test_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,83 @@ jobs:
path: |
test/traces
testDevE2EFirefox:
name: Test Development (E2E) (Firefox)
runs-on: ubuntu-latest
needs: [build, build-native-test]
env:
NEXT_TELEMETRY_DISABLED: 1
NEXT_TEST_JOB: 1
TEST_TIMINGS_TOKEN: ${{ secrets.TEST_TIMINGS_TOKEN }}
BROWSER_NAME: 'firefox'
strategy:
fail-fast: false
matrix:
node: [16, 18]
group: [1, 2, 3]
steps:
- name: Setup node
uses: actions/setup-node@v3
if: ${{needs.build.outputs.docsChange == 'nope'}}
with:
node-version: ${{ matrix.node }}
check-latest: true

- run: echo ${{needs.build.outputs.docsChange}}

# https://github.com/actions/virtual-environments/issues/1187
- name: tune linux network
run: sudo ethtool -K eth0 tx off rx off

- uses: actions/cache@v3
if: ${{needs.build.outputs.docsChange == 'nope'}}
id: restore-build
with:
path: ./*
key: ${{ github.sha }}-${{ github.run_number }}

- uses: actions/download-artifact@v3
if: ${{needs.build.outputs.docsChange == 'nope'}}
with:
name: next-swc-test-binary
path: packages/next-swc/native

- run: npm i -g pnpm@${PNPM_VERSION}
if: ${{needs.build.outputs.docsChange == 'nope'}}

- run: npm i -g playwright-chromium@1.22.2 && npx playwright install-deps
if: ${{needs.build.outputs.docsChange == 'nope'}}

- run: npx @replayio/playwright install chromium
if: ${{needs.build.outputs.docsChange == 'nope'}}

- run: node run-tests.js --type e2e --timings -g ${{ matrix.group }}/3 --debug
name: Run test/e2e (dev)
if: ${{needs.build.outputs.docsChange == 'nope'}}
env:
RECORD_REPLAY_METADATA_TEST_RUN_TITLE: testDevE2E / Group ${{ matrix.group }} / Node ${{ matrix.node }}
RECORD_ALL_CONTENT: 1
RECORD_REPLAY: 1
NEXT_TEST_MODE: dev
# DEBUG: pw:browser*

- uses: replayio/action-upload@v0.4.5
if: always()
with:
api-key: rwk_1LfNb6DteBpcQbb5dcy3XZbo1jidYqN5qQr5uYYfiVt
public: true
filter: ${{ 'function($v) { $v.metadata.test.result = "failed" }' }}

- name: Upload test trace
if: always()
uses: actions/upload-artifact@v3
with:
name: test-trace
if-no-files-found: ignore
retention-days: 2
path: |
test/traces
testDevE2EReact17:
name: Test Development (E2E) (react v17)
runs-on: ubuntu-latest
Expand Down

0 comments on commit 0138854

Please sign in to comment.