This repository has been archived by the owner on Nov 28, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
37 lines (30 loc) · 1.47 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
language: node_js
node_js:
- 13
jobs:
include:
env:
- BROOKJS_SUITE=unit
- BROOKJS_SUITE=js
- BROOKJS_SUITE=ts
before_install:
- |
if [[ $BROOKJS_SUITE == 'unit' ]]; then
curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter;
chmod +x ./cc-test-reporter;
fi
before_script:
- yarn build
- if [[ $BROOKJS_SUITE == 'js' ]]; then cd packages/brookjs-cli && node package-project.mjs --js && cd .. && cd ..; fi
- if [[ $BROOKJS_SUITE == 'ts' ]]; then cd packages/brookjs-cli && node package-project.mjs --ts && cd .. && cd ..; fi
script:
- yarn $BROOKJS_SUITE
after_script:
- |
if [[ $BROOKJS_SUITE == 'unit' ]]; then
./cc-test-reporter format-coverage $PWD/packages/brookjs/coverage/lcov.info --input-type lcov --output $PWD/coverage/codeclimate.brookjs.json;
./cc-test-reporter format-coverage $PWD/packages/brookjs-cli/coverage/lcov.info --input-type lcov --output $PWD/coverage/codeclimate.brookjs-cli.json;
./cc-test-reporter format-coverage $PWD/packages/brookjs-desalinate/coverage/lcov.info --input-type lcov --output $PWD/coverage/codeclimate.brookjs-desalinate.json;
./cc-test-reporter format-coverage $PWD/packages/brookjs-silt/coverage/lcov.info --input-type lcov --output $PWD/coverage/codeclimate.brookjs-silt.json;
./cc-test-reporter sum-coverage --output - --parts 4 $PWD/coverage/codeclimate.*.json | ./cc-test-reporter upload-coverage --input -;
fi