Skip to content

Commit

Permalink
Adapted test coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
brickpop committed Dec 11, 2024
1 parent 5ea7441 commit bd2e7b0
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ docs/
.env
.env.test

lcov.info
lcov.info*
report/
.DS_Store

*.tree
Expand Down
7 changes: 4 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ deploy-prodnet: export ETHERSCAN_API_KEY_PARAM = --etherscan-api-key $(ETHERSCAN

# CONSTANTS

TEST_COVERAGE_SRC_FILES:=$(wildcard test/*.sol test/**/*.sol script/*.sol script/**/*.sol src/escrow/increasing/delegation/*.sol src/libs/ProxyLib.sol)
TEST_COVERAGE_SRC_FILES:=$(wildcard test/*.sol test/**/*.sol src/*.sol src/**/*.sol src/libs/ProxyLib.sol)
DEPLOY_SCRIPT:=script/Deploy.s.sol:Deploy
VERBOSITY:=-vvv
SHELL:=/bin/bash
Expand Down Expand Up @@ -68,10 +68,11 @@ report/index.html: lcov.info.pruned
genhtml $^ -o report --branch-coverage

lcov.info.pruned: lcov.info
lcov --remove ./$< -o ./$@ $^
lcov --remove $< -o ./$@ $^

lcov.info: $(TEST_COVERAGE_SRC_FILES)
forge coverage --no-match-path $(FORK_TEST_WILDCARD) --report lcov
forge coverage --report lcov
# forge coverage --no-match-path $(FORK_TEST_WILDCARD) --report lcov

: ##

Expand Down
12 changes: 5 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -448,14 +448,12 @@ Then use `make` to automatically sync the described branches into solidity test
```sh
$ make
Available targets:
- make all Builds all tree files and updates the test tree markdown
- make sync Scaffold or sync tree files into solidity tests
- make check Checks if solidity files are out of sync
- make markdown Generates a markdown file with the test definitions rendered as a tree
- make init Check the dependencies and prompt to install if needed
- make clean Clean the intermediary tree files
# ...
- make sync-tests Scaffold or sync tree files into solidity tests
- make check-tests Checks if solidity files are out of sync
- make markdown-tests Generates a markdown file with the test definitions rendered as a tree
$ make sync
$ make sync-tests
```

The final output will look like a human readable tree:
Expand Down

0 comments on commit bd2e7b0

Please sign in to comment.