mirror of
https://github.com/nasa/openmct.git
synced 2024-12-24 07:16:39 +00:00
Add codecov.io and make general CircleCI Improvements (#4375)
This commit is contained in:
parent
c4a87ae5d7
commit
1e11bbc2ad
@ -13,8 +13,6 @@ jobs:
|
|||||||
type: string
|
type: string
|
||||||
browser:
|
browser:
|
||||||
type: string
|
type: string
|
||||||
always-pass:
|
|
||||||
type: boolean
|
|
||||||
executor: linux
|
executor: linux
|
||||||
steps:
|
steps:
|
||||||
- checkout
|
- checkout
|
||||||
@ -24,13 +22,18 @@ jobs:
|
|||||||
node-version: << parameters.node-version >>
|
node-version: << parameters.node-version >>
|
||||||
- node/install-packages:
|
- node/install-packages:
|
||||||
override-ci-command: npm install
|
override-ci-command: npm install
|
||||||
- when: # Just to save time until caching saves the browser bin
|
- when:
|
||||||
condition:
|
condition:
|
||||||
equal: [ "FirefoxESR", <<parameters.browser>> ]
|
equal: [ "FirefoxESR", <<parameters.browser>> ]
|
||||||
steps:
|
steps:
|
||||||
- browser-tools/install-firefox:
|
- browser-tools/install-firefox:
|
||||||
version: "78.11.0esr" #https://archive.mozilla.org/pub/firefox/releases/
|
version: "91.2.0esr" #https://archive.mozilla.org/pub/firefox/releases/
|
||||||
- when: # Just to save time until caching saves the browser bin
|
- when:
|
||||||
|
condition:
|
||||||
|
equal: [ "Firefox", <<parameters.browser>> ]
|
||||||
|
steps:
|
||||||
|
- browser-tools/install-firefox
|
||||||
|
- when:
|
||||||
condition:
|
condition:
|
||||||
equal: [ "ChromeHeadless", <<parameters.browser>> ]
|
equal: [ "ChromeHeadless", <<parameters.browser>> ]
|
||||||
steps:
|
steps:
|
||||||
@ -42,8 +45,15 @@ jobs:
|
|||||||
- ~/.npm
|
- ~/.npm
|
||||||
- ~/.cache
|
- ~/.cache
|
||||||
- node_modules
|
- node_modules
|
||||||
|
- when:
|
||||||
|
condition:
|
||||||
|
equal: [ "", <<parameters.browser>> ] #Only run linting when browsers are not running to save time
|
||||||
|
steps:
|
||||||
- run: npm run lint
|
- run: npm run lint
|
||||||
- run: npm run test:coverage -- --browsers=<<parameters.browser>> || <<parameters.always-pass>>
|
- when:
|
||||||
|
condition: << parameters.browser >> #Truthy evaluation to only run when browser is specified
|
||||||
|
steps:
|
||||||
|
- run: npm run test:coverage -- --browsers=<<parameters.browser>>
|
||||||
- store_test_results:
|
- store_test_results:
|
||||||
path: dist/reports/tests/
|
path: dist/reports/tests/
|
||||||
- store_artifacts:
|
- store_artifacts:
|
||||||
@ -52,37 +62,36 @@ workflows:
|
|||||||
matrix-tests:
|
matrix-tests:
|
||||||
jobs:
|
jobs:
|
||||||
- test:
|
- test:
|
||||||
|
post-steps:
|
||||||
|
- run:
|
||||||
|
command:
|
||||||
|
curl -Os https://uploader.codecov.io/latest/linux/codecov;chmod +x codecov;./codecov
|
||||||
name: node10-chrome
|
name: node10-chrome
|
||||||
node-version: lts/dubnium
|
node-version: lts/dubnium
|
||||||
browser: ChromeHeadless
|
browser: ChromeHeadless
|
||||||
always-pass: false
|
|
||||||
- test:
|
- test:
|
||||||
name: node12-firefoxESR-build-only
|
name: node12-build-only
|
||||||
node-version: lts/erbium
|
node-version: lts/erbium
|
||||||
browser: FirefoxESR
|
browser: "" #Skip testing
|
||||||
always-pass: true
|
|
||||||
- test:
|
- test:
|
||||||
name: node14-chrome-build-only
|
name: node14-build-only
|
||||||
node-version: lts/fermium
|
node-version: lts/fermium
|
||||||
browser: ChromeHeadless
|
browser: "" #Skip testing
|
||||||
always-pass: true
|
|
||||||
nightly:
|
nightly:
|
||||||
jobs:
|
jobs:
|
||||||
- test:
|
- test:
|
||||||
name: node10-chrome-nightly
|
name: node10-chrome-nightly
|
||||||
node-version: lts/dubnium
|
node-version: lts/dubnium
|
||||||
browser: ChromeHeadless
|
browser: ChromeHeadless
|
||||||
always-pass: false
|
|
||||||
- test:
|
- test:
|
||||||
name: node12-firefoxESR-nightly
|
name: node12-firefoxESR-nightly
|
||||||
node-version: lts/erbium
|
node-version: lts/erbium
|
||||||
browser: FirefoxESR
|
browser: FirefoxESR
|
||||||
always-pass: false
|
|
||||||
- test:
|
- test:
|
||||||
name: node14-chrome-nightly
|
name: node14-firefox-nightly
|
||||||
node-version: lts/fermium
|
node-version: lts/fermium
|
||||||
browser: ChromeHeadless
|
browser: Firefox
|
||||||
always-pass: false
|
|
||||||
triggers:
|
triggers:
|
||||||
- schedule:
|
- schedule:
|
||||||
cron: "0 0 * * *"
|
cron: "0 0 * * *"
|
||||||
|
3
.gitignore
vendored
3
.gitignore
vendored
@ -44,3 +44,6 @@ report.*.json
|
|||||||
.lighthouseci
|
.lighthouseci
|
||||||
|
|
||||||
package-lock.json
|
package-lock.json
|
||||||
|
|
||||||
|
#codecov artifacts
|
||||||
|
codecov
|
||||||
|
20
codecov.yml
Normal file
20
codecov.yml
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
codecov:
|
||||||
|
require_ci_to_pass: false
|
||||||
|
|
||||||
|
coverage:
|
||||||
|
precision: 2
|
||||||
|
round: down
|
||||||
|
range: "70...100"
|
||||||
|
|
||||||
|
parsers:
|
||||||
|
gcov:
|
||||||
|
branch_detection:
|
||||||
|
conditional: yes
|
||||||
|
loop: yes
|
||||||
|
method: no
|
||||||
|
macro: no
|
||||||
|
|
||||||
|
comment:
|
||||||
|
layout: "reach,diff,flags,files,footer"
|
||||||
|
behavior: default
|
||||||
|
require_changes: false
|
Loading…
Reference in New Issue
Block a user