diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7d2ca707..fd6b1269 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -86,14 +86,7 @@ jobs: path: target/wasm32-wasi/release/ - name: Test CLI - env: - CARGO_PROFILE_RELEASE_LTO: off - run: | - cargo build --package=javy-core --target=wasm32-wasi --release - cargo test --package=javy-cli --release -- --nocapture - - cargo build --package=javy-core --target=wasm32-wasi --release --features=experimental_event_loop - cargo test --package=javy-cli --features=experimental_event_loop --release -- --nocapture + run: CARGO_PROFILE_RELEASE_LTO=off cargo test --package=javy-cli --release -- --nocapture - name: Check benchmarks run: CARGO_PROFILE_RELEASE_LTO=off cargo check --package=javy-cli --release --benches diff --git a/.github/workflows/cli-features.yml b/.github/workflows/cli-features.yml new file mode 100644 index 00000000..df2ad3bb --- /dev/null +++ b/.github/workflows/cli-features.yml @@ -0,0 +1,26 @@ +# Tests extra CLI features as and their dependency with core features. +name: Test CLI Features +on: + push: + branches: + - main + pull_request: + +jobs: + cli: + name: test_cli + runs_on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: ./.github/actions/ci-shared-setup + with: + os: linux + + - name: Test `experimental_event_loop` + run: | + cargo build --package=javy-core --target=wasm32-wasi --release --features=experimental_event_loop + cargo test --package=javy-cli --features=experimental_event_loop --release -- --nocapture + + + diff --git a/crates/cli/tests/integration_test.rs b/crates/cli/tests/integration_test.rs index 6d769101..ab8e85ac 100644 --- a/crates/cli/tests/integration_test.rs +++ b/crates/cli/tests/integration_test.rs @@ -96,11 +96,7 @@ fn test_logging() -> Result<()> { "hello world from console.log\nhello world from console.error\n", logs.as_str(), ); - if cfg!(feature = "experimental_event_loop") { - assert_fuel_consumed_within_threshold(39602, fuel_consumed); - } else { - assert_fuel_consumed_within_threshold(34169, fuel_consumed); - } + assert_fuel_consumed_within_threshold(34169, fuel_consumed); Ok(()) }