Code coverage improvements (#656)

* Add check for coverage threshold

* Rename WrapEth foundry test file to .t.sol
This commit is contained in:
Elena 2023-02-08 09:04:17 +02:00 committed by GitHub
parent 8c35931041
commit f2f835591e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 2 deletions

View File

@ -98,7 +98,7 @@ jobs:
- name: Run Forge coverage - name: Run Forge coverage
working-directory: contracts/zero-ex working-directory: contracts/zero-ex
run: | run: |
forge coverage --report lcov forge coverage --report summary --report lcov
- name: Upload the coverage report to Coveralls - name: Upload the coverage report to Coveralls
uses: coverallsapp/github-action@master uses: coverallsapp/github-action@master
@ -106,3 +106,10 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }} github-token: ${{ secrets.GITHUB_TOKEN }}
base-path: ./contracts/zero-ex/ base-path: ./contracts/zero-ex/
path-to-lcov: ./contracts/zero-ex/lcov.info path-to-lcov: ./contracts/zero-ex/lcov.info
- name: Check coverage threshold
uses: VeryGoodOpenSource/very_good_coverage@v2
with:
path: ./contracts/zero-ex/lcov.info
min_coverage: 6.98
exclude: '**/tests'

View File

@ -29,7 +29,7 @@ import "src/transformers/bridges/BridgeProtocols.sol";
import "src/transformers/bridges/EthereumBridgeAdapter.sol"; import "src/transformers/bridges/EthereumBridgeAdapter.sol";
import "src/IZeroEx.sol"; import "src/IZeroEx.sol";
contract WrapEth is Test, ForkUtils, TestUtils { contract WrapEthTest is Test, ForkUtils, TestUtils {
DeployZeroEx.ZeroExDeployed zeroExDeployed; DeployZeroEx.ZeroExDeployed zeroExDeployed;
function setUp() public { function setUp() public {