-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
56 lines (50 loc) · 1.43 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
language: node_js
node_js:
- '12'
git:
depth: false
cache:
directories:
- ~/.cache/yarn
- ~/.cache/Cypress
install:
# install dependencies
- yarn install --frozen-lockfile
# just in case the install script skipped Cypress post-install hook for some reason
# call install ourselves. If there is binary already installed, it will quickly finish.
# By overriding the install step we make sure the NPM modules AND the Cypress binary
# are installed before the cache is saved
- yarn cypress install
# good idea to verify the binary so its status is saved in the cache as well
- yarn cypress verify
# check that Cypress can run
before_script:
# where is Cypress binary cached?
- yarn cypress cache path
# show me all versions of Cypress binary cached
- yarn cypress cache list
script:
- yarn run affected:build -- --base=origin/master --parallel --with-deps
- yarn run coverage
- yarn run affected:lint -- --base=origin/master --parallel
- yarn e2e angular-e2e --headless
- yarn run format
- 'if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sonar-scanner; fi' # sonar only on non-PRs
deploy:
- provider: releases
api_key: $GITHUB_TOKEN
file_glob: true
file: build/*
skip_cleanup: true
on:
tags: true
- provider: npm
email: $NPM_EMAIL
api_key: $NPM_TOKEN
skip_cleanup: true
on:
tags: true
addons:
sonarcloud:
organization: 'naetverkjs'
token: $SONAR_TOKEN