test(e2e): don't wait for streamed search responses to finish (#15735)

This commit is contained in:
Shrinath Rao
2026-10-24 05:49:38 +00:00
committed by GitHub
parent df9a274df3
commit d6628752ad
2 changed files with 9 additions and 2 deletions
@@ -338,7 +338,11 @@ export default class DashboardactionPage {
{ timeout: 30000 }
);
await this.applyDashboardBtn();
await (await promqlResponse).finished();
const response = await promqlResponse;
// A streamed (text/event-stream) response never reports finished; waitForChartToRender covers completion.
if (!(await response.headerValue("content-type"))?.includes("text/event-stream")) {
await response.finished();
}
await this.waitForChartToRender();
}
+4 -1
View File
@@ -13382,7 +13382,10 @@ export class LogsPage {
),
this.page.locator(this.searchBarRefreshButton).click(),
]);
await response.finished();
// A streamed (text/event-stream) response never reports finished; the Run button wait covers completion.
if (!(await response.headerValue('content-type'))?.includes('text/event-stream')) {
await response.finished();
}
await this.waitForRunQueryButton(timeout);
await expect(this.resultsTable()).toBeVisible({ timeout });
}