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

test(repo): Fix wasm error on coverage #193

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
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
3 changes: 2 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ env:
CARGO_TERM_COLOR: always
CLICOLOR: 1
RUST_NIGHTLY_VERSION: nightly-2024-07-28
RUST_NIGHTLY_COV: nightly-2024-06-05
CI: true

concurrency:
Expand Down Expand Up @@ -222,7 +223,7 @@ jobs:
- name: Install Rust
uses: ./.github/actions/setup-rust
with:
toolchain: ${{ env.RUST_NIGHTLY_VERSION }}
toolchain: ${{ env.RUST_NIGHTLY_COV }}
target: x86_64-unknown-linux-gnu,wasm32-unknown-unknown
cache: false

Expand Down
1 change: 0 additions & 1 deletion Cargo.lock

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

21 changes: 13 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,18 @@ clap = { version = "4.5", features = ["derive", "env"] }
dotenvy = "0.15"
displaydoc = "0.2.5"
futures = "0.3"
fuel-core-bin = { version = "0.34", features = ["p2p", "relayer", "rocksdb"] }
fuel-core = { version = "0.34", features = ["p2p", "relayer", "rocksdb"] }
fuel-core-client = { version = "0.34" }
fuel-core-importer = { version = "0.34" }
fuel-core-storage = { version = "0.34" }
fuel-core-types = { version = "0.34", features = ["test-helpers", "serde"] }
fuel-core-services = "0.34"
fuel-core-bin = { version = "0.34", default-features = false, features = [
"p2p",
"relayer",
"rocksdb",
] }
fuel-core = { version = "0.34", default-features = false, features = ["p2p", "relayer", "rocksdb"] }
fuel-core-importer = { version = "0.34", default-features = false }
fuel-core-storage = { version = "0.34", default-features = false }
fuel-core-types = { version = "0.34", default-features = false, features = [
"test-helpers",
"serde",
] }
futures-util = "0.3.30"
pretty_assertions = "1.4.0"
rand = "0.8"
Expand All @@ -50,7 +55,7 @@ subject-derive = { version = "0.0.6", path = "crates/fuel-streams-macros/subject

# Workspace projects
[workspace.metadata.cargo-machete]
ignored = ["fuel-core", "tokio"]
ignored = ["tokio"]

[profile.release]
opt-level = 3
Expand Down
5 changes: 4 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
PACKAGE ?= fuel-streams-publisher
DOCKER_PROFILE ?= all
RUST_NIGHTLY_VERSION ?= nightly-2024-07-28
RUST_NIGHTLY_COV ?= nightly-2024-06-05

.PHONY: all build clean lint fmt help setup start stop restart clean/docker start/nats stop/nats restart/nats clean/nats start/fuel-core stop/fuel-core restart/fuel-core clean/fuel-core dev-watch fmt-cargo fmt-rust fmt-markdown fmt-yaml check lint-cargo lint-rust lint-clippy lint-markdown audit audit-fix-test audit-fix test doc bench

Expand Down Expand Up @@ -98,7 +99,9 @@ lint-markdown:
# ------------------------------------------------------------

coverage:
RUSTFLAGS="-Z threads=8" cargo +$(RUST_NIGHTLY_VERSION) tarpaulin --config ./tarpaulin.toml
cargo +$(RUST_NIGHTLY_COV) tarpaulin \
--config ./tarpaulin.toml \
--rustflags="-Z threads=8"

# ------------------------------------------------------------
# Audit crates
Expand Down
39 changes: 17 additions & 22 deletions tarpaulin.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "Fuel Data Parser Coverage Analysis"
packages = ["fuel-data-parser"]
all-features = true
run-types = ["Lib", "Tests"]
run-types = ["Lib", "Tests", "Doctests"]
timeout = "120s"
color = "Always"
locked = true
Expand All @@ -18,7 +18,7 @@ engine = "Llvm"
name = "Fuel Streams Coverage Analysis"
packages = ["fuel-streams"]
all-features = true
run-types = ["Lib", "Tests"]
run-types = ["Lib", "Tests", "Doctests"]
timeout = "120s"
color = "Always"
locked = true
Expand All @@ -34,7 +34,7 @@ engine = "Llvm"
name = "Fuel Streams Core Coverage Analysis"
packages = ["fuel-streams-core"]
all-features = true
run-types = ["Lib", "Tests"]
run-types = ["Lib", "Tests", "Doctests"]
timeout = "120s"
color = "Always"
locked = true
Expand All @@ -50,7 +50,7 @@ engine = "Llvm"
name = "Fuel Streams Macros Coverage Analysis"
packages = ["fuel-streams-macros"]
all-features = true
run-types = ["Lib", "Tests"]
run-types = ["Lib", "Tests", "Doctests"]
timeout = "120s"
color = "Always"
locked = true
Expand All @@ -62,24 +62,19 @@ engine = "Llvm"
#fail-under = 80

# ==========================================
# ignore due to wasm incompatibility
# [cov_fuel_streams_publisher]
# name = "Fuel Streams Publisher Coverage Analysis"
# packages = [
# "fuel-streams-publisher"
# ]
# all-features = true
# run-types = [
# "Tests"
# ]
# timeout = "120s"
# color = "Always"
# locked = true
# count = true
# no-dead-code = true
# fail-immediately = true
# skip-clean = true
# engine = "Llvm"
[cov_fuel_streams_publisher]
name = "Fuel Streams Publisher Coverage Analysis"
packages = ["fuel-streams-publisher"]
all-features = true
run-types = ["Tests"]
timeout = "120s"
color = "Always"
locked = true
count = true
no-dead-code = true
fail-immediately = true
skip-clean = true
engine = "Llvm"
#fail-under = 80

# ==========================================
Expand Down
Loading