MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / first_read_is_a_miss

Function first_read_is_a_miss

crates/virtual-machine/tests/vm_cache.rs:41–46  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

39
40#[test]
41fn first_read_is_a_miss() {
42 let mut c = make_cache(256, 64, 2, true);
43 c.read_byte(RAM_BASE).expect("cache access should succeed");
44 assert_eq!(c.stats().read_misses, 1);
45 assert_eq!(c.stats().read_hits, 0);
46}
47
48#[test]
49fn second_read_same_block_is_a_hit() {

Callers

nothing calls this directly

Calls 2

make_cacheFunction · 0.70
read_byteMethod · 0.45

Tested by

no test coverage detected