Skip to content

Commit

Permalink
[7.x] fix some missing awaits in functional tests (elastic#58807) (el…
Browse files Browse the repository at this point in the history
…astic#58823)

Co-authored-by: Elastic Machine <[email protected]>
  • Loading branch information
Spencer and elasticmachine authored Mar 2, 2020
1 parent 7dc4808 commit d007b0a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion test/functional/apps/context/_filters.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export default function({ getService, getPageObjects }) {
await filterBar.toggleFilterEnabled(TEST_ANCHOR_FILTER_FIELD);
await PageObjects.context.waitUntilContextLoadingHasFinished();

retry.try(async () => {
await retry.try(async () => {
expect(
await filterBar.hasFilter(TEST_ANCHOR_FILTER_FIELD, TEST_ANCHOR_FILTER_VALUE, false)
).to.be(true);
Expand Down
2 changes: 1 addition & 1 deletion test/functional/apps/dashboard/panel_expand_toggle.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export default function({ getService, getPageObjects }) {

// Add a retry to fix https://github.com/elastic/kibana/issues/14574. Perhaps the recent changes to this
// being a CSS update is causing the UI to change slower than grabbing the panels?
retry.try(async () => {
await retry.try(async () => {
const panelCountAfterMaxThenMinimize = await PageObjects.dashboard.getPanelCount();
expect(panelCountAfterMaxThenMinimize).to.be(panelCount);
});
Expand Down
4 changes: 2 additions & 2 deletions test/functional/apps/visualize/_tsvb_markdown.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {
await visualBuilder.markdownSwitchSubTab('data');
await visualBuilder.cloneSeries();

retry.try(async function seriesCountCheck() {
await retry.try(async function seriesCountCheck() {
const seriesLength = (await visualBuilder.getSeries()).length;
expect(seriesLength).to.be.equal(2);
});
Expand All @@ -131,7 +131,7 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {
await visualBuilder.markdownSwitchSubTab('data');
await visualBuilder.createNewAgg();

retry.try(async function aggregationCountCheck() {
await retry.try(async function aggregationCountCheck() {
const aggregationLength = await visualBuilder.getAggregationCount();
expect(aggregationLength).to.be.equal(2);
});
Expand Down
2 changes: 1 addition & 1 deletion x-pack/test/functional/page_objects/uptime_page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export function UptimePageProvider({ getPageObjects, getService }: FtrProviderCo
}

public async pageUrlContains(value: string, expected: boolean = true) {
retry.try(async () => {
await retry.try(async () => {
expect(await uptimeService.urlContains(value)).to.eql(expected);
});
}
Expand Down

0 comments on commit d007b0a

Please sign in to comment.