From ecff1ac25bfe3c6bc41a3bee7785e19454c1d331 Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Sat, 10 Oct 2026 20:46:21 +0200 Subject: [PATCH] Call record tests: resumed and exact-cap cases keep one cap per run Co-Authored-By: Claude Opus 5.5 --- crates/ghostlight/src/verse/calls/tests.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/ghostlight/src/verse/calls/tests.rs b/crates/ghostlight/src/verse/calls/tests.rs index ca88565..30a51e8 100644 --- a/crates/ghostlight/src/verse/calls/tests.rs +++ b/crates/ghostlight/src/verse/calls/tests.rs @@ -270,7 +270,7 @@ async fn cap_refuses_before_the_provider_is_called() { drop(port); // Exactly the cap is allowed. - let exact = recording(&inner, &store, "run-cap", bound); + let exact = recording(&inner, &store, "run-exact-cap", bound); exact .infer(probe) .await @@ -592,13 +592,13 @@ async fn a_reopened_run_resumes_its_spend() { let inner = ScriptedPort::new(vec![Ok( reply("one", "r1").with_usage(usage(bound, 0, None)) )]); - let first = recording(&inner, &store, "run-resume", bound * 2); + let first = recording(&inner, &store, "run-resume", bound * 2 - 1); first.infer(probe.clone()).await.unwrap(); drop((first, store)); let store = Arc::new(CallRecordStore::open(&path).unwrap()); let inner = ScriptedPort::new(vec![Ok(reply("two", "r2"))]); - let resumed = recording(&inner, &store, "run-resume", bound * 2); + let resumed = recording(&inner, &store, "run-resume", bound * 2 - 1); assert_eq!(resumed.spent(), bound); let fault = resumed .infer(probe)