Skip to content

Commit

Permalink
fix: use kcov for code coverage provider
Browse files Browse the repository at this point in the history
  • Loading branch information
enmand committed Feb 26, 2024
1 parent 30d3b49 commit 9552376
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 162 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,10 @@ jobs:
- name: Run CI
uses: actions-rs/cargo@v1
env:
CARGO_MAKE_COVERAGE_PROVIDER: "grcov"
CARGO_MAKE_RUN_CODECOV: true
with:
command: make
args: workspace-ci-flow
args: --no-workspace workspace-ci-flow
toolchain: stable
wasm-tests:
runs-on: ubuntu-latest
Expand Down
20 changes: 15 additions & 5 deletions Makefile.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
extend = [{ path = "makefile.d/coverage_grcov.makefile.toml" }]

[env]
CARGO_MAKE_COVERAGE_PROVIDER = "kcov"
CARGO_MAKE_RUN_CODECOV = true
CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = true
CARGO_MAKE_CARGO_BUILD_TEST_FLAGS = "--lib --release"

Expand All @@ -9,7 +9,16 @@ workspace = false
cwd = "crates/dwn-rs-wasm"
command = "wasm-pack"
args = [
"build", "--target", "nodejs", "--out-name", "index", "--release", "--", "--no-default-features", "--features", "surrealdb-wasm",
"build",
"--target",
"nodejs",
"--out-name",
"index",
"--release",
"--",
"--no-default-features",
"--features",
"surrealdb-wasm",
]
dependencies = ["install-wasm-pack"]

Expand All @@ -26,5 +35,6 @@ command = "node"
args = ["node_modules/mocha/bin/mocha.js", "tests/test.js", "--bail", "--exit"]
dependencies = ["build-wasm", "install-npm-deps"]

[tasks.coverage]
alias = "coverage_grcov"
[tasks.test-cargo]
command = "cargo"
args = ["test", "--release", "--", "--nocapture"]
155 changes: 0 additions & 155 deletions makefile.d/coverage_grcov.makefile.toml

This file was deleted.

0 comments on commit 9552376

Please sign in to comment.