2020-05-17 11:02:36 +03:00
|
|
|
dist: bionic
|
|
|
|
|
2018-08-04 11:29:55 +03:00
|
|
|
language: node_js
|
|
|
|
|
2020-06-10 19:43:11 +03:00
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
- /.*/
|
|
|
|
|
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- node_modules
|
|
|
|
|
2020-09-19 17:57:35 +03:00
|
|
|
node_js:
|
2020-10-31 13:58:07 +03:00
|
|
|
- '14.15.0'
|
2020-09-19 17:57:35 +03:00
|
|
|
|
2020-05-17 11:02:36 +03:00
|
|
|
jobs:
|
|
|
|
fast_finish: true
|
2020-09-19 19:08:16 +03:00
|
|
|
allow_failures:
|
2020-11-14 14:10:42 +03:00
|
|
|
- name: 'Lint'
|
2020-09-19 19:08:16 +03:00
|
|
|
- name: 'Mutation tests'
|
2020-05-17 11:02:36 +03:00
|
|
|
include:
|
2020-09-19 19:52:49 +03:00
|
|
|
|
2020-09-19 17:57:35 +03:00
|
|
|
- name: 'Lint'
|
|
|
|
install: npm ci
|
|
|
|
script: npm run lint
|
2020-09-19 19:52:49 +03:00
|
|
|
|
2020-09-19 17:57:35 +03:00
|
|
|
- name: 'Unit tests'
|
|
|
|
install: npm ci
|
|
|
|
script: npm run test:ci
|
|
|
|
after_success:
|
|
|
|
- node_modules/.bin/ocular coverage/clover.xml
|
2020-09-19 19:52:49 +03:00
|
|
|
|
2020-09-19 17:57:35 +03:00
|
|
|
- name: 'Mutation tests'
|
|
|
|
install: npm ci
|
|
|
|
before_script:
|
|
|
|
- echo "Building commit range ${TRAVIS_COMMIT_RANGE}"
|
|
|
|
- export MUTATION_FILES=$(git diff ${TRAVIS_COMMIT_RANGE:-origin/main} --name-only | grep -E 'src\/(.*).(ts|tsx)$' | paste -sd ",")
|
|
|
|
script: npm run mutate:ci
|
2020-09-19 19:52:49 +03:00
|
|
|
|
2020-09-19 17:57:35 +03:00
|
|
|
- name: 'Build docker image'
|
|
|
|
services:
|
|
|
|
- docker
|
|
|
|
script: docker build -t shlink-web-client:test .
|