File tree 4 files changed +14
-5
lines changed
4 files changed +14
-5
lines changed Original file line number Diff line number Diff line change 30
30
npm install
31
31
env :
32
32
CI : true
33
+ - name : Unit tests with Jest
34
+ uses : mattallty/jest-github-action@v1
35
+ with :
36
+ changes-only : false
37
+ test-command : npm test:unit
38
+ - name : Code Coverage Report
39
+ uses : codecov/codecov-action@v1
40
+ with :
41
+ file : ./coverage/jest/coverage-final.json # optional
42
+ fail_ci_if_error : true # optional (default = false)
33
43
- name : End-to-end Tests with Cypress
34
44
uses : cypress-io/github-action@v1
35
45
with :
47
57
uses : codecov/codecov-action@v1
48
58
with :
49
59
token : ${{ secrets.CODECOV_TOKEN }} # not required for public repos
50
- file : ./coverag* /coverage-final.json # optional
60
+ file : ./coverage/cypress /coverage-final.json # optional
51
61
fail_ci_if_error : true # optional (default = false)
52
62
- name : Build PWA distribution for production
53
63
run : |
Original file line number Diff line number Diff line change @@ -26,5 +26,4 @@ cypress/screenshots/
26
26
27
27
# Test coverage reports
28
28
.nyc_output /
29
- coverage /
30
- coverage-jest /
29
+ coverage /
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ module.exports = {
13
13
'.*\\.vue$' : 'vue-jest'
14
14
} ,
15
15
collectCoverage : true ,
16
- coverageDirectory : "./coverage- jest" ,
16
+ coverageDirectory : "./coverage/ jest/ " ,
17
17
coverageReporters : [ "json" ] ,
18
18
collectCoverageFrom : [
19
19
'<rootDir>/**/*.vue' ,
Original file line number Diff line number Diff line change 7
7
"serve" : " vue-cli-service serve" ,
8
8
"build" : " vue-cli-service build" ,
9
9
"lint" : " vue-cli-service lint" ,
10
- "codecov" : " codecov -f coverage/coverage-final.json && codecov -f coverage- jest/coverage-final.json" ,
10
+ "codecov" : " codecov -f coverage/coverage-final.json && codecov -f coverage/ jest/coverage-final.json" ,
11
11
"test:unit" : " jest" ,
12
12
"test:e2e" : " npx cypress run" ,
13
13
"test" : " npm run test:unit && npm run test:e2e"
You can’t perform that action at this time.
0 commit comments