MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / TEST

Function TEST

crates/c-api/tests/module.cc:7–16  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5using namespace wasmtime;
6
7TEST(Module, Simple) {
8 Engine engine;
9 Module m = Module::compile(engine, "(module)").unwrap();
10 auto wasm = wat2wasm("(module)").unwrap();
11 Module::compile(engine, wasm).unwrap();
12 Module::validate(engine, wasm).unwrap();
13
14 auto serialized = m.serialize().unwrap();
15 Module::deserialize(engine, serialized).unwrap();
16}

Callers

nothing calls this directly

Calls 6

wat2wasmFunction · 0.85
compileFunction · 0.50
validateFunction · 0.50
deserializeFunction · 0.50
unwrapMethod · 0.45
serializeMethod · 0.45

Tested by

no test coverage detected