MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / deferred

Function deferred

graph-ui/src/adr/AdrWorkspace.refresh.test.tsx:26–30  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

24afterEach(async () => { await act(async () => root.unmount()); host.remove(); clearAdrDraft(project); });
25
26function deferred<T>() {
27 let resolve!: (value: T) => void, reject!: (reason: unknown) => void;
28 const promise = new Promise<T>((yes, no) => { resolve = yes; reject = no; });
29 return { promise, resolve, reject };
30}
31const refresh = () => [...host.querySelectorAll('.adr-actions button')][0] as HTMLButtonElement;
32const status = () => host.querySelector('.adr-actions .atlas-refresh-status')?.textContent;
33const TIME = '\\d\\d:\\d\\d:\\d\\d';

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected