mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
91eb74519c
* chore: ensure new-docs are up to date This adds a Travis check that if we re-generate the docs we get the exact output (by checking if the Git tree is dirty). We do the dirty check by using `git status --porcelain`, seeing how many lines that outputs, and using that as the exit code (taking only the first 255 lines to avoid invalid exit codes). `--porcelain` makes the output be empty if the repo is not dirty in anyway which translates into an exit code of 0. We can't use `git diff-index --quiet HEAD` as it exits with 0 if there are untracked files in the repo but we want that to cause a failure.
84 lines
2.1 KiB
YAML
84 lines
2.1 KiB
YAML
language: node_js
|
|
services: xvfb
|
|
|
|
jobs:
|
|
include:
|
|
- os: "osx"
|
|
name: 'Unit tests: macOS/Chromium'
|
|
node_js: "10.19.0"
|
|
osx_image: xcode11.4
|
|
env:
|
|
- CHROMIUM=true
|
|
before_install:
|
|
- PUPPETEER_PRODUCT=firefox npm install
|
|
script:
|
|
- ls .local-chromium .local-firefox
|
|
- npm run tsc
|
|
- travis_retry npm run unit
|
|
|
|
- os: "windows"
|
|
name: 'Unit tests: Windows/Chromium'
|
|
node_js: "10.19.0"
|
|
env:
|
|
- CHROMIUM=true
|
|
before_install:
|
|
- PUPPETEER_PRODUCT=firefox npm install
|
|
script:
|
|
- ls .local-chromium .local-firefox
|
|
- npm run tsc
|
|
- travis_retry npm run unit
|
|
|
|
# Runs unit tests on Linux + Chromium
|
|
- node_js: "10.19.0"
|
|
name: 'Unit tests [with coverage]: Linux/Chromium'
|
|
env:
|
|
- CHROMIUM=true
|
|
before_install:
|
|
- PUPPETEER_PRODUCT=firefox npm install
|
|
script:
|
|
- travis_retry npm run unit-with-coverage
|
|
- npm run assert-unit-coverage
|
|
|
|
- node_js: "12.16.3"
|
|
name: 'Unit tests [Node 12]: Linux/Chromium'
|
|
env:
|
|
- CHROMIUM=true
|
|
before_install:
|
|
- PUPPETEER_PRODUCT=firefox npm install
|
|
script:
|
|
- travis_retry npm run unit
|
|
|
|
- node_js: "14.2.0"
|
|
name: 'Unit tests [Node 14]: Linux/Chromium'
|
|
env:
|
|
- CHROMIUM=true
|
|
before_install:
|
|
- PUPPETEER_PRODUCT=firefox npm install
|
|
script:
|
|
- travis_retry npm run unit
|
|
|
|
# This bot runs all the extra checks that aren't the main Puppeteer unit tests
|
|
- node_js: "10.19.0"
|
|
name: 'Extra tests: Linux/Chromium'
|
|
env:
|
|
- CHROMIUM=true
|
|
script:
|
|
- npm run compare-protocol-d-ts
|
|
- npm run test-install
|
|
- npm run lint
|
|
- npm run test-doclint
|
|
- npm run ensure-new-docs-up-to-date
|
|
|
|
# Runs unit tests on Linux + Firefox
|
|
- node_js: "10.19.0"
|
|
name: 'Unit tests: Linux/Firefox'
|
|
env:
|
|
- FIREFOX=true
|
|
before_install:
|
|
- PUPPETEER_PRODUCT=firefox npm install
|
|
script:
|
|
- travis_retry npm run funit
|
|
|
|
notifications:
|
|
email: false
|