()
| 63 | #[test] |
| 64 | #[cfg_attr(miri, ignore)] |
| 65 | fn test_module_serialize_fail() -> Result<()> { |
| 66 | let buffer = serialize( |
| 67 | &Engine::default(), |
| 68 | "(module (func (export \"run\") (result i32) i32.const 42))", |
| 69 | )?; |
| 70 | |
| 71 | let mut config = Config::new(); |
| 72 | config.memory_reservation(0); |
| 73 | let mut store = Store::new(&Engine::new(&config)?, ()); |
| 74 | match unsafe { deserialize_and_instantiate(&mut store, &buffer) } { |
| 75 | Ok(_) => bail!("expected failure at deserialization"), |
| 76 | Err(_) => (), |
| 77 | } |
| 78 | Ok(()) |
| 79 | } |
| 80 | |
| 81 | #[test] |
| 82 | #[cfg_attr(miri, ignore)] |
nothing calls this directly
no test coverage detected