Skip to content

Commit

Permalink
ci: Fix codecov upload (#99)
Browse files Browse the repository at this point in the history
  • Loading branch information
mtrezza authored Oct 18, 2024
1 parent 91390d3 commit 067cb87
Show file tree
Hide file tree
Showing 5 changed files with 71 additions and 129 deletions.
11 changes: 10 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,13 @@ jobs:
- run: npm test
env:
CI: true
- run: bash <(curl -s https://codecov.io/bash)
- name: Upload code coverage
uses: codecov/codecov-action@v4
with:
fail_ci_if_error: false
token: ${{ secrets.CODECOV_TOKEN }}
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
10 changes: 10 additions & 0 deletions .nycrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"reporter": [
"lcov",
"text-summary"
],
"exclude": [
"**/spec/**"
]
}

166 changes: 41 additions & 125 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,14 @@
"@semantic-release/git": "10.0.1",
"@semantic-release/npm": "10.0.3",
"@semantic-release/release-notes-generator": "11.0.1",
"@types/jasmine": "5.1.4",
"@types/node": "22.7.6",
"babel-eslint": "10.1.0",
"codecov": "3.8.3",
"eslint": "7.32.0",
"eslint-plugin-flowtype": "5.9.0",
"form-data": "4.0.0",
"jasmine": "3.9.0",
"jasmine-spec-reporter": "7.0.0",
"madge": "5.0.1",
"mailgun.js": "3.5.9",
"nyc": "15.1.0",
Expand All @@ -63,8 +65,7 @@
"lint:fix": "eslint '{src,spec,demo}/**/*.js' --fix",
"madge": "node_modules/.bin/madge ./src $npm_config_arg",
"madge:circular": "npm run madge --arg=--circular",
"test": "nyc --reporter=lcov jasmine",
"posttest": "nyc report --reporter=json && codecov -f coverage/*.json",
"test": "nyc jasmine",
"prepare": "npm run build && npm test",
"demo": "node ./demo"
}
Expand Down
6 changes: 6 additions & 0 deletions spec/helper.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
const SpecReporter = require('jasmine-spec-reporter').SpecReporter;

// Set up jasmine
jasmine.DEFAULT_TIMEOUT_INTERVAL = 10000;
jasmine.getEnv().addReporter(new SpecReporter());

// Simulate Parse User class
const Parse = {
User: class User {
Expand Down

0 comments on commit 067cb87

Please sign in to comment.