lighthouse/.travis.yml

58 строки
1.5 KiB
YAML

sudo: required
language: node_js
branches:
only:
- master
matrix:
include:
- node_js: "12"
cache:
yarn: true
directories:
- node_modules
- lantern-data
- lighthouse-core/scripts/legacy-javascript/variants
- /home/travis/.rvm/gems/
install:
# Ensure we have the latest Chrome stable.
- google-chrome-stable --version
# We used to set PUPPETEER_SKIP_CHROMIUM_DOWNLOAD, but we don't want to anymore.
# Explicitly unset b/c environment variables seem to linger in travis.
# see https://github.com/GoogleChrome/lighthouse/pull/9877#discussion_r338389765
- unset PUPPETEER_SKIP_CHROMIUM_DOWNLOAD
- yarn --frozen-lockfile
before_script:
# see comment above about puppeteer
- export CHROME_PATH="$(which google-chrome-stable)"
# Print out the Chrome version so we know what we're working with
- google-chrome-stable --version
- yarn build-all
script:
- yarn diff:sample-json
- yarn lint
- yarn test-legacy-javascript
- yarn unit:cicoverage
- yarn type-check
- yarn smoke:cicoverage
- yarn test-clients
- yarn test-viewer
- yarn test-treemap
- yarn test-lantern
- yarn test-bundle
- yarn i18n:checks
- yarn dogfood-lhci
- yarn test-docs
# Fail if any changes were written to source files (ex, from: build/build-cdt-lib.js).
- git diff --exit-code
before_cache:
# nyc, jest and other projects store files in here. They mess up the travis build cache.
- rm -rf ./node_modules/.cache/
after_success:
- yarn coveralls
- yarn codecov
addons:
chrome: stable
services:
- xvfb