MCPcopy Index your code
hub / github.com/github/copilot-sdk / waitForExchanges

Function waitForExchanges

nodejs/test/e2e/session.e2e.test.ts:17–27  ·  view source on GitHub ↗
(minimumCount = 1)

Source from the content-addressed store, hash-verified

15 } = await createSdkTestContext();
16
17 async function waitForExchanges(minimumCount = 1) {
18 await retry(
19 `capture ${minimumCount} chat completion request(s)`,
20 async () => {
21 const exchanges = await openAiEndpoint.getExchanges();
22 expect(exchanges.length).toBeGreaterThanOrEqual(minimumCount);
23 },
24 1_200
25 );
26 return openAiEndpoint.getExchanges();
27 }
28
29 it.each([
30 ["stdio", () => RuntimeConnection.forStdio({ path: process.env.COPILOT_CLI_PATH })],

Callers 1

Calls 2

retryFunction · 0.90
getExchangesMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…