playwright/.github/workflows/tests.yml
Andrey Lushnikov 5c9ebfaa79
chore(ci): bump checkout action to v2 (#1263)
This should fix the checkout problems we're facing.
Related discussion: https://github.com/actions/checkout/issues/23
2020-03-06 09:40:54 -08:00

200 lines
5.2 KiB
YAML

name: tests
on:
push:
branches:
- master
pull_request:
branches:
- master
env:
CI: true
# Force terminal colors. @see https://www.npmjs.com/package/colors
FORCE_COLOR: 1
jobs:
chromium_linux:
name: "Chromium Linux"
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- name: install required packages
run: |
sudo apt-get update
sudo apt-get install libgbm-dev xvfb
- run: npm install
# XVFB-RUN merges both STDOUT and STDERR, whereas we need only STDERR
# Wrap `npm run` in a subshell to redirect STDERR to file.
- run: xvfb-run --auto-servernum -- bash -c "npm run ccoverage 2>./chromium-linux-testrun.log"
env:
DEBUG: "*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: chromium-linux-testrun.log
path: chromium-linux-testrun.log
chromium_mac:
name: "Chromium Mac"
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- run: npm install
- run: npm run ctest 2>./chromium-mac-testrun.log
env:
DEBUG: "*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: chromium-mac-testrun.log
path: chromium-mac-testrun.log
chromium_win:
name: "Chromium Win"
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- run: npm install
- run: npm run ctest 2>./chromium-win-testrun.log
shell: bash
env:
DEBUG: "*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: chromium-win-testrun.log
path: chromium-win-testrun.log
webkit_linux:
name: "WebKit Linux"
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- name: install required packages
run: |
sudo apt-get update
sudo apt-get install libwoff1 libopus0 libwebp6 libwebpdemux2 libenchant1c2a libgudev-1.0-0 libsecret-1-0 libhyphen0 libgdk-pixbuf2.0-0 libegl1 libgles2 libevent-2.1-6 libnotify4 libxslt1.1
sudo apt-get install xvfb
- run: npm install
# XVFB-RUN merges both STDOUT and STDERR, whereas we need only STDERR
# Wrap `npm run` in a subshell to redirect STDERR to file.
- run: xvfb-run --auto-servernum -- bash -c "npm run wcoverage 2>./webkit-linux-testrun.log"
env:
DEBUG: "*,-pw:wrapped*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: webkit-linux-testrun.log
path: webkit-linux-testrun.log
webkit_mac:
name: "WebKit Mac"
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- run: npm install
- run: npm run wtest 2>./webkit-mac-testrun.log
env:
DEBUG: "*,-pw:wrapped*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: webkit-mac-testrun.log
path: webkit-mac-testrun.log
webkit_win:
name: "WebKit Win"
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- run: npm install
- run: npm run wtest -- --verbose 2>./webkit-win-testrun.log
shell: bash
env:
DEBUG: "*,-pw:wrapped*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: webkit-win-testrun.log
path: webkit-win-testrun.log
firefox_linux:
name: "Firefox Linux"
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- name: install required packages
run: |
sudo apt-get update
sudo apt-get install xvfb
- run: npm install
# XVFB-RUN merges both STDOUT and STDERR, whereas we need only STDERR
# Wrap `npm run` in a subshell to redirect STDERR to file.
- run: xvfb-run --auto-servernum -- bash -c "npm run fcoverage 2>./firefox-linux-testrun.log"
env:
DEBUG: "*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: firefox-linux-testrun.log
path: firefox-linux-testrun.log
firefox_mac:
name: "Firefox Mac"
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- run: npm install
- run: npm run ftest 2>./firefox-mac-testrun.log
env:
DEBUG: "*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: firefox-mac-testrun.log
path: firefox-mac-testrun.log
firefox_win:
name: "Firefox Win"
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10.15
- run: npm install
- run: npm run ftest 2>./firefox-win-testrun.log
shell: bash
env:
DEBUG: "*"
- uses: actions/upload-artifact@v1
if: failure()
with:
name: firefox-win-testrun.log
path: firefox-win-testrun.log