Module test

Source
Expand description

Functions and types useful for writing tests.

Functionsยง

assert_interface_dependencies
Asserts that the WIT type dependencies of the Interface are the expected_types.
assert_interface_functions
Asserts that the function declarations of the Interface are the expected_declarations.
test_flattening_roundtrip
Test lowering an instance of T, checking that the resulting flat layout matches the expected flat_layout, and check that the instance can be lifted from that flat layout.
test_memory_roundtrip
Test storing an instance of T to memory, checking that the instance can be loaded from those bytes.