worker: cover parent teardown scope reclaim

This commit is contained in:
2026-08-07 01:52:07 +09:00
parent e0ac732769
commit cc7266c801
+17
View File
@@ -942,6 +942,23 @@ mod tests {
.unwrap(); .unwrap();
assert!(registry.get_internal("reviewer-child").is_none()); assert!(registry.get_internal("reviewer-child").is_none());
assert!(spawner_scope.snapshot().is_writable(&workspace_root)); assert!(spawner_scope.snapshot().is_writable(&workspace_root));
let mut teardown_input = input;
teardown_input["name"] = serde_json::json!("reviewer-child-parent-drop");
tool.execute(
&serde_json::to_string(&teardown_input).unwrap(),
llm_engine::tool::ToolExecutionContext::direct(),
)
.await
.unwrap();
assert!(!spawner_scope.snapshot().is_writable(&workspace_root));
drop(list);
drop(read);
drop(send);
drop(stop);
drop(tool);
drop(registry);
assert!(spawner_scope.snapshot().is_writable(&workspace_root));
} }
#[test] #[test]