owncast/.github/workflows/browser-testing.yml

55 lines
1.3 KiB
YAML
Raw Normal View History

name: Browser Tests
on:
push:
paths:
- 'web/**'
- 'test/automated/browser/**'
pull_request:
paths:
- 'web/**'
- 'test/automated/browser/**'
2023-03-18 02:24:17 +01:00
jobs:
cypress-run:
runs-on: ubuntu-latest
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@v5
with:
concurrent_skipping: 'same_content_newer'
- name: Checkout
uses: actions/checkout@v4
2022-12-11 03:33:50 +01:00
2023-03-18 02:24:17 +01:00
- uses: actions/setup-node@v3
with:
2023-03-18 02:24:17 +01:00
node-version: 18.9.0
2023-02-15 23:46:45 +01:00
- name: Cache node modules
uses: actions/cache@v3
2023-02-15 23:46:45 +01:00
env:
cache-name: cache-node-modules-browser-tests
with:
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('test/automated/browser/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- uses: actions/setup-go@v4
2023-03-18 02:24:17 +01:00
with:
2023-03-24 20:50:52 +01:00
go-version: '1.20'
2023-03-18 02:24:17 +01:00
cache: true
- name: Install Google Chrome
run: sudo apt-get update && sudo apt-get install google-chrome-stable
2023-03-18 02:24:17 +01:00
- name: Run Browser tests
2022-12-11 03:33:50 +01:00
uses: nick-fields/retry@v2
with:
2023-01-16 20:36:40 +01:00
timeout_minutes: 20
2022-12-11 03:33:50 +01:00
max_attempts: 3
command: cd test/automated/browser && ./run.sh