mirror of
https://github.com/microsoft/playwright.git
synced 2024-12-04 06:03:10 +03:00
1a577ac344
This patch: - rolls stable-test-runner to Nov 2, 2021 tip-of-tree - introduces a new npm script, `npm run vtest`, to run Visual Regression Tests for our HTML reporter
96 lines
2.5 KiB
YAML
96 lines
2.5 KiB
YAML
name: "tests 1"
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
- release-*
|
|
pull_request:
|
|
paths-ignore:
|
|
- 'browser_patches/**'
|
|
- 'docs/**'
|
|
branches:
|
|
- master
|
|
- release-*
|
|
|
|
env:
|
|
# Force terminal colors. @see https://www.npmjs.com/package/colors
|
|
FORCE_COLOR: 1
|
|
FLAKINESS_CONNECTION_STRING: ${{ secrets.FLAKINESS_CONNECTION_STRING }}
|
|
|
|
jobs:
|
|
test_linux:
|
|
name: ${{ matrix.os }} (${{ matrix.browser }})
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
browser: [chromium, firefox, webkit]
|
|
os: [ubuntu-20.04]
|
|
runs-on: ${{ matrix.os }}
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 12
|
|
- run: npm i -g npm@7
|
|
- run: npm ci
|
|
env:
|
|
DEBUG: pw:install
|
|
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
- run: npm run build
|
|
- run: npx playwright install --with-deps ${{ matrix.browser }} chromium
|
|
- run: xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- npm run test -- --project=${{ matrix.browser }}
|
|
- run: node tests/config/checkCoverage.js ${{ matrix.browser }}
|
|
- run: ./utils/upload_flakiness_dashboard.sh ./test-results/report.json
|
|
if: always()
|
|
- uses: actions/upload-artifact@v1
|
|
if: always()
|
|
with:
|
|
name: ${{ matrix.browser }}-${{ matrix.os }}-test-results
|
|
path: test-results
|
|
|
|
test_test_runner:
|
|
name: Test Runner
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
os: [ubuntu-latest, windows-latest, macos-latest]
|
|
runs-on: ${{ matrix.os }}
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 12
|
|
- run: npm i -g npm@7
|
|
- run: npm ci
|
|
env:
|
|
DEBUG: pw:install
|
|
- run: npm run build
|
|
- run: npx playwright install --with-deps
|
|
- run: npm run ttest
|
|
if: matrix.os != 'ubuntu-latest'
|
|
- run: xvfb-run npm run ttest
|
|
if: matrix.os == 'ubuntu-latest'
|
|
|
|
test_runner_vrt:
|
|
name: Test Runner Visual Regression Testing
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 12
|
|
- run: npm i -g npm@7
|
|
- run: npm ci
|
|
env:
|
|
DEBUG: pw:install
|
|
- run: npm run build
|
|
- run: npx playwright install --with-deps
|
|
- run: cd tests/playwright-test/stable-test-runner && npx playwright install docker-image
|
|
- run: npm run vtest
|
|
- uses: actions/upload-artifact@v1
|
|
if: ${{ always() }}
|
|
with:
|
|
name: visual-regression-testing
|
|
path: test-results
|