MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / registry_remove

Function registry_remove

crates/openshell-server/src/supervisor_session.rs:927–940  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

925
926 #[test]
927 fn registry_remove() {
928 let registry = SupervisorSessionRegistry::new();
929 let (tx, _rx) = mpsc::channel(1);
930 registry.register(
931 "sandbox-1".to_string(),
932 "s1".to_string(),
933 tx,
934 make_shutdown(),
935 );
936
937 registry.remove("sandbox-1");
938 let sessions = registry.sessions.lock().unwrap();
939 assert!(!sessions.contains_key("sandbox-1"));
940 }
941
942 #[test]
943 fn remove_if_current_removes_matching_session() {

Callers

nothing calls this directly

Calls 3

make_shutdownFunction · 0.85
registerMethod · 0.45
removeMethod · 0.45

Tested by

no test coverage detected