use grcov to get rust code coverage

This commit is contained in:
realaravinth
2021-11-25 14:09:42 +05:30
parent c438ea3b2d
commit 5d46ef3a58
4 changed files with 98 additions and 18 deletions

View File

@ -5,7 +5,8 @@ clean: ## Clean all build artifacts and dependencies
@cargo clean
coverage: ## Generate HTML code coverage
cargo tarpaulin -t 1200 --out Html
./scripts/coverage.sh --coverage
dev-env: ## Download development dependencies
cargo fetch
@ -33,8 +34,5 @@ run: default ## Run debug build
test: ## Run tests
cargo test --all-features --no-fail-fast
xml-test-coverage: ## Generate cobertura.xml test coverage
cargo tarpaulin -t 1200 --out Xml
help: ## Prints help for targets with comments
@cat $(MAKEFILE_LIST) | grep -E '^[a-zA-Z_-]+:.*?## .*$$' | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'