Assert listSessions reflects bootstrap session when startup succeeds
Co-authored-by: Theo Browne <[email protected]>
This commit is contained in:
1 parent
c4b7956430
commit
f997cc3716
1 file changed
+9
@@ -1675,6 +1675,7 @@ async function main() {
|
||||
) {
|
||||
throw new Error("Smoke test failed: app.bootstrap response payload mismatch.");
|
||||
}
|
||||
const bootstrapSessionId = bootstrapResponse.result.session.sessionId;
|
||||
|
||||
const listedSessionsResponse = await sendWsRequest(ws, {
|
||||
id: "smoke-providers-list-sessions",
|
||||
@@ -1688,6 +1689,14 @@ async function main() {
|
||||
throw new Error("Smoke test failed: providers.listSessions entry missing sessionId.");
|
||||
}
|
||||
}
|
||||
const listedIncludesBootstrap = listedSessionsResponse.result.some(
|
||||
(session) => session?.sessionId === bootstrapSessionId,
|
||||
);
|
||||
if (!bootstrapResponse.result.bootstrapError && !listedIncludesBootstrap) {
|
||||
throw new Error(
|
||||
`Smoke test failed: providers.listSessions did not include bootstrap session ${bootstrapSessionId}.`,
|
||||
);
|
||||
}
|
||||
|
||||
const todoTitle = `Smoke todo ${String(backendPort)}-${String(webPort)}-${Date.now()}`;
|
||||
const addedTodosResponse = await sendWsRequest(ws, {
|
||||
|
||||
Reference in new issue
Block a user