Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stop travis recording cypress runs #169

Closed
wants to merge 17 commits into from
Closed
46 changes: 16 additions & 30 deletions .github/workflows/test-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,22 @@ on: [pull_request]
jobs:
test:
runs-on: ${{ matrix.platform }}
env:
CI: true

strategy:
fail-fast: false
matrix:
node-version: ['10.x', '12.10.x']
node-version: ['10.x', '12.x']
platform: [ubuntu-latest, macos-latest, windows-latest]
runner: [npm, yarn]
include:
- platform: ubuntu-latest
browser: chrome
return-node-version: ls $RUNNER_TOOL_CACHE/node
- platform: windows-latest
browser: chrome
return-node-version: gci C:\hostedtoolcache\windows\node |% FullName
- platform: macos-latest
browser: electron
return-node-version: ls $RUNNER_TOOL_CACHE/node

steps:
- uses: actions/checkout@v1
Expand All @@ -30,39 +29,26 @@ jobs:
- uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: install packages
env:
CI: true
- name: install packages and show matrix input
run: |
echo === matrix variables ===
echo ${{ matrix.platform }}
echo ${{ matrix.node-version }}
echo ${{ matrix.runner }}
echo === exact node version ===
${{ matrix.return-node-version }}
${{ matrix.runner }} install
- name: run tests
env:
CI: true
run: ${{ matrix.runner }} run test
- name: run build
env:
CI: true
run: ${{ matrix.runner }} run build
- run: ${{ matrix.runner }} run test
- run: ${{ matrix.runner }} run build
- name: install build host for cypress
env:
CI: true
run: npm install -g pushstate-server
- name: run cypress (record)
- name: cypress run
uses: cypress-io/github-action@v1
with:
config-file: cypress-config.json
record: true
parallel: true
group: ${{ matrix.runner }}
browser: ${{ matrix.browser }}
start: pushstate-server -d ./build -p 8080
wait-on: 'http://localhost:8080'
env:
CI: true
CYPRESS_BASE_URL: http://localhost:8080
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
if: matrix.runner == 'yarn' && matrix.platform == 'ubuntu-latest' && matrix.node-version == '10.x'
run: npx start-server-and-test "pushstate-server -d ./build -p 8080" 8080 "${{ matrix.runner }} run cy:run -- --ci-build-id ${{ github.ref }}/${{ github.sha }} --record --parallel --browser electron"
- name: run cypress
env:
CI: true
CYPRESS_BASE_URL: http://localhost:8080
if: matrix.runner != 'yarn' || matrix.platform != 'ubuntu-latest' || matrix.node-version != '10.x'
run: npx start-server-and-test "pushstate-server -d ./build -p 8080" 8080 "${{ matrix.runner }} run cy:run -- --browser ${{ matrix.browser }}"
94 changes: 0 additions & 94 deletions .travis.yml

This file was deleted.