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

Function bforest_map

crates/fuzzing/tests/oom/bforest_map.rs:7–19  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5
6#[test]
7fn bforest_map() -> Result<()> {
8 OomTest::new().test(|| {
9 let mut forest = MapForest::new();
10 let mut map = Map::new();
11 for i in 0..100 {
12 map.try_insert(Key(i), i, &mut forest, &())?;
13 }
14 for i in 0..100 {
15 assert_eq!(map.get(Key(i), &forest, &()), Some(i));
16 }
17 Ok(())
18 })
19}

Callers

nothing calls this directly

Calls 5

OkFunction · 0.85
KeyClass · 0.70
newFunction · 0.50
testMethod · 0.45
try_insertMethod · 0.45

Tested by

no test coverage detected