Skip to content

Commit

Permalink
[Discover] Improve functional testing searchOnPageLoad (elastic#107181)…
Browse files Browse the repository at this point in the history
… (elastic#107363)

Co-authored-by: Matthias Wilhelm <[email protected]>
  • Loading branch information
kibanamachine and kertal authored Aug 2, 2021
1 parent 44890da commit c357330
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/functional/apps/discover/_discover.ts
Original file line number Diff line number Diff line change
Expand Up @@ -298,8 +298,10 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
await kibanaServer.uiSettings.replace({ 'discover:searchOnPageLoad': true });
await PageObjects.common.navigateToApp('discover');
await PageObjects.header.awaitKibanaChrome();

expect(await PageObjects.discover.getNrOfFetches()).to.be(1);
await retry.waitFor('number of fetches to be 1', async () => {
const nrOfFetches = await PageObjects.discover.getNrOfFetches();
return nrOfFetches === 1;
});
});
});

Expand Down

0 comments on commit c357330

Please sign in to comment.