MCPcopy Create free account
hub / github.com/GongShichen/LuminaCode / waitUntilMissing

Function waitUntilMissing

test/task_tools_parity_test.go:643–653  ·  view source on GitHub ↗
(t *testing.T, rt *agent.AgentTaskRuntime, taskID, scopeID string)

Source from the content-addressed store, hash-verified

641 for time.Now().Before(deadline) {
642 record := rt.GetTask(taskID, scopeID)
643 if record != nil && record.Status == status {
644 return
645 }
646 time.Sleep(10 * time.Millisecond)
647 }
648 t.Fatalf("task %s did not reach status %s; record=%#v", taskID, status, rt.GetTask(taskID, scopeID))
649}
650
651func waitUntilMissing(t *testing.T, rt *agent.AgentTaskRuntime, taskID, scopeID string) {
652 t.Helper()
653 deadline := time.Now().Add(3 * time.Second)
654 for time.Now().Before(deadline) {
655 if rt.GetTask(taskID, scopeID) == nil {
656 return

Calls 2

AddMethod · 0.80
GetTaskMethod · 0.80

Tested by

no test coverage detected