2020-05-17 10:02:36 +02:00
|
|
|
dist: bionic
|
|
|
|
|
2018-08-04 10:29:55 +02:00
|
|
|
language: node_js
|
|
|
|
|
2020-06-10 18:43:11 +02:00
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
- /.*/
|
|
|
|
|
|
|
|
cache:
|
|
|
|
directories:
|
|
|
|
- node_modules
|
|
|
|
|
2020-09-19 16:57:35 +02:00
|
|
|
node_js:
|
2020-10-31 11:58:07 +01:00
|
|
|
- '14.15.0'
|
2020-09-19 16:57:35 +02:00
|
|
|
|
2020-05-17 10:02:36 +02:00
|
|
|
jobs:
|
|
|
|
fast_finish: true
|
2020-09-19 18:08:16 +02:00
|
|
|
allow_failures:
|
2020-11-14 12:10:42 +01:00
|
|
|
- name: 'Lint'
|
2020-09-19 18:08:16 +02:00
|
|
|
- name: 'Mutation tests'
|
2020-05-17 10:02:36 +02:00
|
|
|
include:
|
2020-09-19 18:52:49 +02:00
|
|
|
|
2020-09-19 16:57:35 +02:00
|
|
|
- name: 'Lint'
|
|
|
|
install: npm ci
|
|
|
|
script: npm run lint
|
2020-09-19 18:52:49 +02:00
|
|
|
|
2020-09-19 16:57:35 +02:00
|
|
|
- name: 'Unit tests'
|
|
|
|
install: npm ci
|
|
|
|
script: npm run test:ci
|
|
|
|
after_success:
|
|
|
|
- node_modules/.bin/ocular coverage/clover.xml
|
2020-09-19 18:52:49 +02:00
|
|
|
|
2020-09-19 16:57:35 +02: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 18:52:49 +02:00
|
|
|
|
2020-09-19 16:57:35 +02:00
|
|
|
- name: 'Build docker image'
|
|
|
|
services:
|
|
|
|
- docker
|
2020-12-06 11:57:14 +01:00
|
|
|
install: skip
|
2020-09-19 16:57:35 +02:00
|
|
|
script: docker build -t shlink-web-client:test .
|