Skip to content

Commit b405ec6

Browse files
author
Pat Hickey
committed
gen-host-wasmtime-rust: tests work exclusively on smoke
1 parent b50c33d commit b405ec6

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

crates/gen-host-wasmtime-rust/tests/codegen.rs

+6-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ fn main() {
77
#[rustfmt::skip]
88
mod exports {
99
test_helpers::codegen_wasmtime_export!(
10-
"*.wit"
10+
"!*.wit"
11+
"smoke.wit"
1112

1213
// If you want to exclude a specific test you can include it here with
1314
// gitignore glob syntax:
@@ -24,10 +25,12 @@ mod exports {
2425
#[rustfmt::skip]
2526
mod imports {
2627
test_helpers::codegen_wasmtime_import!(
27-
"*.wit"
28+
"!*.wit"
29+
"smoke.wit"
2830
);
2931
}
3032

33+
/*
3134
mod custom_errors {
3235
wit_bindgen_host_wasmtime_rust::export!({
3336
src["x"]: "
@@ -42,3 +45,4 @@ mod custom_errors {
4245
custom_error: true,
4346
});
4447
}
48+
*/

crates/gen-host-wasmtime-rust/tests/runtime.rs

+5-3
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use wasmtime::{
66
Config, Engine, Store,
77
};
88

9-
test_helpers::runtime_tests_wasmtime!();
9+
test_helpers::runtime_tests_wasmtime!("!*" "smoke");
1010

1111
fn default_config() -> Result<Config> {
1212
// Create an engine with caching enabled to assist with iteration in this
@@ -18,14 +18,16 @@ fn default_config() -> Result<Config> {
1818
Ok(config)
1919
}
2020

21+
/*
2122
fn default_wasi() -> wasmtime_wasi::WasiCtx {
2223
wasmtime_wasi::sync::WasiCtxBuilder::new()
2324
.inherit_stdio()
2425
.build()
2526
}
27+
*/
2628

2729
struct Context<I, E> {
28-
wasi: wasmtime_wasi::WasiCtx,
30+
//wasi: wasmtime_wasi::WasiCtx,
2931
imports: I,
3032
exports: E,
3133
}
@@ -49,7 +51,7 @@ fn instantiate<I: Default, E: Default, T>(
4951
let mut store = Store::new(
5052
&engine,
5153
Context {
52-
wasi: default_wasi(),
54+
//wasi: default_wasi(),
5355
imports: I::default(),
5456
exports: E::default(),
5557
},

0 commit comments

Comments
 (0)