()
| 112 | // Running simple wat |
| 113 | #[test] |
| 114 | fn run_wasmtime_simple_wat() -> Result<()> { |
| 115 | let wasm = build_wasm("tests/all/cli_tests/simple.wat")?; |
| 116 | run_wasmtime(&[ |
| 117 | "run", |
| 118 | "--invoke", |
| 119 | "simple", |
| 120 | "-Ccache=n", |
| 121 | wasm.path().to_str().unwrap(), |
| 122 | "4", |
| 123 | ])?; |
| 124 | assert_eq!( |
| 125 | run_wasmtime(&[ |
| 126 | "run", |
| 127 | "--invoke", |
| 128 | "get_f32", |
| 129 | "-Ccache=n", |
| 130 | wasm.path().to_str().unwrap(), |
| 131 | ])?, |
| 132 | "100\n" |
| 133 | ); |
| 134 | assert_eq!( |
| 135 | run_wasmtime(&[ |
| 136 | "run", |
| 137 | "--invoke", |
| 138 | "get_f64", |
| 139 | "-Ccache=n", |
| 140 | wasm.path().to_str().unwrap(), |
| 141 | ])?, |
| 142 | "100\n" |
| 143 | ); |
| 144 | Ok(()) |
| 145 | } |
| 146 | |
| 147 | // Running a wat that traps. |
| 148 | #[test] |
nothing calls this directly
no test coverage detected