From 7fdcfd885bdf82df3cf1fc2246ab718515ba4c00 Mon Sep 17 00:00:00 2001 From: local Date: Wed, 25 Nov 2026 13:46:47 -0600 Subject: [PATCH] Test of parts taken: other tests' notes at the address Co-Authored-By: Claude Opus 5.5 --- crates/victory-gpu/src/watch.rs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/crates/victory-gpu/src/watch.rs b/crates/victory-gpu/src/watch.rs index d08825a..a120b25 100644 --- a/crates/victory-gpu/src/watch.rs +++ b/crates/victory-gpu/src/watch.rs @@ -3627,9 +3627,9 @@ mod tests { unsafe { ((p + at) as *mut u8).write_volatile(1) } }; let tracked = track(p, 4 * PAGE, false).expect("watched"); - write(5); - write(PAGE + 5000); - assert_eq!(tracked.take(p, p + 4 * PAGE), [(p, p + 2 * PAGE)], "never taken"); + // (Other tests' memory was here.) + (0..4).for_each(|page| write(page * PAGE + 5)); + assert_eq!(tracked.take(p, p + 4 * PAGE), [(p, p + 4 * PAGE)], "never taken"); assert!(tracked.take(p, p + 4 * PAGE).is_empty()); write(PAGE + 5000); write(PAGE + 8192); @@ -3637,8 +3637,7 @@ mod tests { write(2 * PAGE); assert_eq!( tracked.take(p, p + 4 * PAGE), - [(p + PAGE + 4096, p + PAGE + 3 * 4096), (p + 2 * PAGE - 4096, p + 3 * PAGE)], - "page 2 was never taken" + [(p + PAGE + 4096, p + PAGE + 3 * 4096), (p + 2 * PAGE - 4096, p + 2 * PAGE + 4096)] ); write(2 * PAGE + 70); // Two askings' writes are in what is taken after both.