Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add code coverage step to circle CI pipeline, add coveralls dependency #246

Merged
merged 4 commits into from
Aug 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
version: 2
version: 2.1
orbs:
coveralls: coveralls/[email protected]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awsome did not know about this 💯

jobs:
build:
working_directory: ~/repo
Expand Down Expand Up @@ -53,8 +55,9 @@ jobs:
cd federator
npm test
- run:
name: bridge unit tests
name: bridge unit tests + coverage
command: |
cd bridge
npm test

npm run coverage
- coveralls/upload:
path_to_lcov: "./bridge/coverage/lcov.info"
4 changes: 4 additions & 0 deletions bridge/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Token Bridge Contracts

## Contract coverage

[![Coverage Status](https://coveralls.io/repos/github/rsksmart/tokenbridge/badge.svg)](https://coveralls.io/github/rsksmart/tokenbridge)

## Install dependencies
Don't use Node 14 as it has issues with truffle, use node 8, 10 or 12.
Install node https://nodejs.org/es/
Expand Down
81 changes: 80 additions & 1 deletion bridge/package-lock.json

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

3 changes: 2 additions & 1 deletion bridge/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"coverage": "npx hardhat coverage",
"size": "npx hardhat size-contracts",
"deploy": "npx hardhat deploy --network",
"deployIntegrationTest": "npm run delpoy rskregtest && npm run deploy development",
"deployIntegrationTest": "npm run deploy rskregtest && npm run deploy development",
"deployLocalIntegrationTest": "npm run deploy development && npm run deploy mirrorDevelopment"
},
"keywords": [
Expand Down Expand Up @@ -50,6 +50,7 @@
},
"devDependencies": {
"axios": ">=0.21.1",
"coveralls": "^3.1.1",
"css-what": ">=5.0.1",
"elliptic": ">=6.5.4",
"glob-parent": ">=5.1.2",
Expand Down