From 2c20913556669183192477462183040f6b69d17a Mon Sep 17 00:00:00 2001 From: Joe Reuter Date: Mon, 7 Dec 2020 18:56:20 +0100 Subject: [PATCH] [Lens] Fix functional test failures (#84979) (#85155) --- x-pack/test/functional/apps/lens/drag_and_drop.ts | 2 +- x-pack/test/functional/apps/lens/rollup.ts | 3 +-- .../functional/es_archives/lens/rollup/config/data.json | 2 +- x-pack/test/functional/page_objects/lens_page.ts | 7 +++++-- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/x-pack/test/functional/apps/lens/drag_and_drop.ts b/x-pack/test/functional/apps/lens/drag_and_drop.ts index b85f36f9f5252..e0130bc394271 100644 --- a/x-pack/test/functional/apps/lens/drag_and_drop.ts +++ b/x-pack/test/functional/apps/lens/drag_and_drop.ts @@ -60,7 +60,7 @@ export default function ({ getPageObjects }: FtrProviderContext) { ]); }); - it.skip('should move the column to compatible dimension group', async () => { + it('should move the column to compatible dimension group', async () => { await PageObjects.lens.switchToVisualization('bar'); expect(await PageObjects.lens.getDimensionTriggersTexts('lnsXY_xDimensionPanel')).to.eql([ 'Top values of @message.raw', diff --git a/x-pack/test/functional/apps/lens/rollup.ts b/x-pack/test/functional/apps/lens/rollup.ts index 8bcfe7631c841..f6882c8aed214 100644 --- a/x-pack/test/functional/apps/lens/rollup.ts +++ b/x-pack/test/functional/apps/lens/rollup.ts @@ -13,8 +13,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { const listingTable = getService('listingTable'); const esArchiver = getService('esArchiver'); - // FLAKY: https://github.com/elastic/kibana/issues/84978 - describe.skip('lens rollup tests', () => { + describe('lens rollup tests', () => { before(async () => { await esArchiver.loadIfNeeded('lens/rollup/data'); await esArchiver.loadIfNeeded('lens/rollup/config'); diff --git a/x-pack/test/functional/es_archives/lens/rollup/config/data.json b/x-pack/test/functional/es_archives/lens/rollup/config/data.json index 268b98542fe11..11645d0d7c575 100644 --- a/x-pack/test/functional/es_archives/lens/rollup/config/data.json +++ b/x-pack/test/functional/es_archives/lens/rollup/config/data.json @@ -29,7 +29,7 @@ "index-pattern" : { "title" : "lens_rolled_up_data", "timeFieldName" : "@timestamp", - "fields" : "[{\"count\":0,\"name\":\"_source\",\"type\":\"_source\",\"esTypes\":[\"_source\"],\"scripted\":false,\"searchable\":false,\"aggregatable\":false,\"readFromDocValues\":false},{\"count\":0,\"name\":\"_id\",\"type\":\"string\",\"esTypes\":[\"_id\"],\"scripted\":false,\"searchable\":true,\"aggregatable\":true,\"readFromDocValues\":false},{\"count\":0,\"name\":\"_type\",\"type\":\"string\",\"esTypes\":[\"_type\"],\"scripted\":false,\"searchable\":true,\"aggregatable\":true,\"readFromDocValues\":false},{\"count\":0,\"name\":\"_index\",\"type\":\"string\",\"esTypes\":[\"_index\"],\"scripted\":false,\"searchable\":true,\"aggregatable\":true,\"readFromDocValues\":false},{\"count\":0,\"name\":\"_score\",\"type\":\"number\",\"scripted\":false,\"searchable\":false,\"aggregatable\":false,\"readFromDocValues\":false},{\"count\":0,\"name\":\"@timestamp\",\"type\":\"date\",\"esTypes\":[\"date\"],\"scripted\":false,\"searchable\":true,\"aggregatable\":true,\"readFromDocValues\":true},{\"count\":0,\"name\":\"bytes\",\"type\":\"number\",\"esTypes\":[\"float\"],\"scripted\":false,\"searchable\":true,\"aggregatable\":true,\"readFromDocValues\":true},{\"count\":0,\"name\":\"geo.src\",\"type\":\"string\",\"esTypes\":[\"keyword\"],\"scripted\":false,\"searchable\":true,\"aggregatable\":true,\"readFromDocValues\":true}]", + "fields" : "[]", "type" : "rollup", "typeMeta" : "{\"params\":{\"rollup_index\":\"lens_rolled_up_data\"},\"aggs\":{\"date_histogram\":{\"@timestamp\":{\"agg\":\"date_histogram\",\"fixed_interval\":\"60m\",\"time_zone\":\"UTC\"}},\"sum\":{\"bytes\":{\"agg\":\"sum\"}},\"max\":{\"bytes\":{\"agg\":\"max\"}},\"terms\":{\"geo.src\":{\"agg\":\"terms\"}}}}" }, diff --git a/x-pack/test/functional/page_objects/lens_page.ts b/x-pack/test/functional/page_objects/lens_page.ts index 1f8ded1716ea1..16a8e0594816f 100644 --- a/x-pack/test/functional/page_objects/lens_page.ts +++ b/x-pack/test/functional/page_objects/lens_page.ts @@ -118,7 +118,7 @@ export function LensPageProvider({ getService, getPageObjects }: FtrProviderCont } if (!opts.keepOpen) { - this.closeDimensionEditor(); + await this.closeDimensionEditor(); } }, @@ -204,7 +204,10 @@ export function LensPageProvider({ getService, getPageObjects }: FtrProviderCont // closes the dimension editor flyout async closeDimensionEditor() { - await testSubjects.click('lns-indexPattern-dimensionContainerBack'); + await retry.try(async () => { + await testSubjects.click('lns-indexPattern-dimensionContainerBack'); + await testSubjects.missingOrFail('lns-indexPattern-dimensionContainerBack'); + }); }, /**