Last active
December 29, 2020 22:29
-
-
Save 4gray/23a9206cf65057c290b0ed7bc9463bb1 to your computer and use it in GitHub Desktop.
Spectron Headless Testing on Github Actions CI
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"require": "ts-node/register", | |
"watch-files": [ | |
"./e2e/**/*.ts" | |
], | |
"timeout": 300000 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Execute e2e tests | |
on: [push] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js | |
uses: actions/setup-node@v1 | |
with: | |
node-version: "12.x" | |
- run: npm install | |
- run: xvfb-run --auto-servernum npm run e2e | |
- run: npm run build:prod | |
env: | |
CI: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"scripts": { | |
"e2e": "npm run build:prod && cross-env TS_NODE_PROJECT='e2e/tsconfig.e2e.json' mocha e2e/**/*.ts --config ./.mocharc.json --exit", | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment