From f2997145361010717dabbeae783c6d4b15bbc1a5 Mon Sep 17 00:00:00 2001 From: mjoerussell Date: Wed, 15 Jan 2025 13:17:31 -0600 Subject: [PATCH] Modify the `infra test cargo` command to run more tests. Previously, the command used to run tests was `cargo nextest run --workspace --all-features --lib --bins --examples --no-fail-fast`. This command ended up skipping the tests in the `metaslang` packages. We can run these as well by changing the command to `cargo nextest run --workspace --exclude solidity_testing_perf --all-features --all-targets --no-fail-fast`. `--exclude solidity_testing_perf` is required because it tries to link with callgrind, which will not be available on all platforms. It's possible that this crash was the reason for the original restrictions in the first place, but I don't know for sure. We can think about different ways to conditionally run those tests in the future, if it's wanted. --- crates/infra/cli/src/commands/test/mod.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/crates/infra/cli/src/commands/test/mod.rs b/crates/infra/cli/src/commands/test/mod.rs index 792a037d1e..89da562a9e 100644 --- a/crates/infra/cli/src/commands/test/mod.rs +++ b/crates/infra/cli/src/commands/test/mod.rs @@ -44,11 +44,10 @@ fn test_cargo() -> Result<()> { Command::new("cargo") .args(["nextest", "run"]) + .args(["--exclude", "solidity_testing_perf"]) // Requires callgrind, which may not be available .flag("--workspace") .flag("--all-features") - .flag("--lib") - .flag("--bins") - .flag("--examples") + .flag("--all-targets") .flag("--no-fail-fast") .add_build_rustflags() .run();