Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

visualize app point series custom labels and axis titles should preserve saved axis titles after a vis is saved and reopened #27905

Closed
liza-mae opened this issue Jan 2, 2019 · 9 comments
Assignees
Labels
failed-test A test failure on a tracked branch, potentially flaky-test high Team:Visualizations Visualization editors, elastic-charts and infrastructure test_ui_functional test

Comments

@liza-mae
Copy link
Contributor

liza-mae commented Jan 2, 2019

Error: retry.try timeout: Error: retry.try timeout: [POST http://localhost:9515/session/7182a7141b2e9ea17c9929de24492679/element / {"using":"partial link text","value":"Visualization Point Series Test"}] no such element: Unable to locate element: {"method":"partial link text","selector":"Visualization Point Series Test"}
(Session info: headless chrome=71.0.3578.98)
(Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.15.0-1026-gcp x86_64)
at Server._post (test/functional/services/remote/verbose_remote_logging.js:34:21)
at runRequest (node_modules/leadfoot/Session.js:92:40)
at node_modules/leadfoot/Session.js:113:39
at new Promise (node_modules/dojo/_debug/Promise.ts:411:4)
at Session._post (node_modules/leadfoot/Session.js:67:10)
at Session.find (node_modules/leadfoot/Session.js:1328:15)
at Command. (node_modules/leadfoot/Command.js:42:36)
at node_modules/dojo/_debug/Promise.ts:393:16
at run (node_modules/dojo/_debug/Promise.ts:237:8)
at node_modules/dojo/_debug/nextTick.ts:44:4
at process._tickCallback (internal/process/next_tick.js:61:11)
at Command.find (node_modules/leadfoot/Command.js:23:10)
at Command.prototype.(anonymous function) [as findByPartialLinkText] (node_modules/leadfoot/lib/strategies.js:29:16)
at _ensureElementWithTimeout (test/functional/services/find.js:203:36)
at retry.try (test/functional/services/find.js:76:33)
at runAttempt (test/common/services/retry/retry_for_success.js:39:21)
at retryForSuccess (test/common/services/retry/retry_for_success.js:67:37)
at lastError (test/common/services/retry/retry_for_success.js:29:9)
at retryForSuccess (test/common/services/retry/retry_for_success.js:63:13)
at lastError (test/common/services/retry/retry_for_success.js:29:9)
at retryForSuccess (test/common/services/retry/retry_for_success.js:63:13)

Branches: 6.5, 6.6, 6.x, master

@liza-mae liza-mae added test_ui_functional Team:Visualizations Visualization editors, elastic-charts and infrastructure failed-test A test failure on a tracked branch, potentially flaky-test labels Jan 2, 2019
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app

@liza-mae liza-mae added the test label Jan 2, 2019
@stacey-gammon
Copy link
Contributor

Failing on master and estf somewhat regularly looks like:

screen shot 2019-01-08 at 10 53 19 am

Standard Output:

[00:07:29]                 └-> should render a custom axis title when one is set, overriding the custom label
[00:07:29]                   └-> "before each" hook: global before each
[00:07:29]                   │ debg find.setValue(#valueAxisTitle0, myTitle)
[00:07:29]                   │ debg findByCssSelector #valueAxisTitle0
[00:07:29]                   │ debg TestSubjects.click(visualizeEditorRenderButton)
[00:07:29]                   │ debg Find.clickByCssSelectorWhenNotDisabled
[00:07:29]                   │ debg findByCssSelector [data-test-subj~="visualizeEditorRenderButton"]
[00:07:29]                   │ debg isGlobalLoadingIndicatorVisible
[00:07:29]                   │ debg TestSubjects.exists(globalLoadingIndicator)
[00:07:29]                   │ debg existsByDisplayedByCssSelector [data-test-subj~="globalLoadingIndicator"]
[00:07:32]                   │ debg awaitGlobalLoadingIndicatorHidden
[00:07:32]                   │ debg TestSubjects.find(globalLoadingIndicator-hidden)
[00:07:32]                   │ debg findByCssSelector [data-test-subj~="globalLoadingIndicator-hidden"]
[00:07:32]                   │ debg Renderable.waitForRender for 2 elements
[00:07:32]                   │ debg in findAllByCssSelector: [data-render-complete="true"]
[00:07:32]                   │ debg in findAllByCssSelector: [data-loading]
[00:07:33]                   │ debg findByCssSelector .y-axis-div .y-axis-title text
[00:07:33]                   └- ✓ pass 
[00:07:33]                 └-> should preserve saved axis titles after a vis is saved and reopened
[00:07:33]                   └-> "before each" hook: global before each
[00:07:33]                   │ debg ensureSavePanelOpen
[00:07:33]                   │ debg TestSubjects.exists(savedObjectSaveModal)
[00:07:33]                   │ debg existsByDisplayedByCssSelector [data-test-subj~="savedObjectSaveModal"]
[00:07:36]                   │ debg TestSubjects.click(visualizeSaveButton)
[00:07:36]                   │ debg clickByCssSelector([data-test-subj~="visualizeSaveButton"])
[00:07:36]                   │ debg findByCssSelector [data-test-subj~="visualizeSaveButton"]
[00:07:36]                   │ debg TestSubjects.exists(savedObjectSaveModal)
[00:07:36]                   │ debg existsByDisplayedByCssSelector [data-test-subj~="savedObjectSaveModal"]
[00:07:36]                   │ debg TestSubjects.click(savedObjectTitle)
[00:07:36]                   │ debg clickByCssSelector([data-test-subj~="savedObjectTitle"])
[00:07:36]                   │ debg findByCssSelector [data-test-subj~="savedObjectTitle"]
[00:07:36]                   │ debg Click Save Visualization button
[00:07:36]                   │ debg TestSubjects.click(confirmSaveSavedObjectButton)
[00:07:36]                   │ debg clickByCssSelector([data-test-subj~="confirmSaveSavedObjectButton"])
[00:07:36]                   │ debg findByCssSelector [data-test-subj~="confirmSaveSavedObjectButton"]
[00:07:36]                   │ debg TestSubjects.exists(saveVisualizationSuccess)
[00:07:36]                   │ debg existsByDisplayedByCssSelector [data-test-subj~="saveVisualizationSuccess"]
[00:07:36]                   │ info [o.e.c.m.MetaDataIndexTemplateService] [kibana-ci-immutable-centos-1546443294981629567] adding template [kibana_index_template:.kibana] for index patterns [.kibana]
[00:07:37]                   │ debg clickByCssSelector([href="#/visualize"])
[00:07:37]                   │ debg findByCssSelector [href="#/visualize"]
[00:07:38]                   │ debg clickVisualizationByLinkText(Visualization Point Series Test)
[00:07:38]                   │ debg clickByPartialLinkText(Visualization Point Series Test)
[00:07:38]                   │ debg find.byPartialLinkText(Visualization Point Series Test)
[00:07:48]                   │ debg --- retry.try error: [POST http://localhost:9515/session/499272fe6307c6d90e89f802eebcaf0f/element / {"using":"partial link text","value":"Visualization Point Series Test"}] no such element: Unable to locate element: {"method":"partial link text","selector":"Visualization Point Series Test"}
[00:07:48]                   │        (Session info: headless chrome=71.0.3578.98)
[00:07:48]                   │        (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 3.10.0-957.1.3.el7.x86_64 x86_64)
[00:07:58]                   │ debg --- retry.try failed again with the same message...
[00:08:09]                   │ debg --- retry.try failed again with the same message...
[00:08:19]                   │ debg --- retry.try failed again with the same message...
[00:08:20]                   │ debg --- retry.try error: retry.try timeout: [POST http://localhost:9515/session/499272fe6307c6d90e89f802eebcaf0f/element / {"using":"partial link text","value":"Visualization Point Series Test"}] no such element: Unable to locate element: {"method":"partial link text","selector":"Visualization Point Series Test"}
[00:08:20]                   │        (Session info: headless chrome=71.0.3578.98)
[00:08:20]                   │        (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 3.10.0-957.1.3.el7.x86_64 x86_64)
[00:08:20]                   │          at Server._post (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/services/remote/verbose_remote_logging.js:34:21)
[00:08:20]                   │          at runRequest (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:92:40)
[00:08:20]                   │          at /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:113:39
[00:08:20]                   │          at new Promise (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/Promise.ts:411:4)
[00:08:20]                   │          at Session._post (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:67:10)
[00:08:20]                   │          at Session.find (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:1328:15)
[00:08:20]                   │          at Command.<anonymous> (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Command.js:42:36)
[00:08:20]                   │          at /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/Promise.ts:393:16
[00:08:20]                   │          at run (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/Promise.ts:237:8)
[00:08:20]                   │          at /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/nextTick.ts:44:4
[00:08:20]                   │          at process._tickCallback (internal/process/next_tick.js:61:11)
[00:08:20]                   │          at Command.find (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Command.js:23:10)
[00:08:20]                   │          at Command.prototype.(anonymous function) [as findByPartialLinkText] (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/lib/strategies.js:29:16)
[00:08:20]                   │          at _ensureElementWithTimeout (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/services/find.js:203:36)
[00:08:20]                   │          at retry.try (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/services/find.js:76:33)
[00:08:20]                   │          at runAttempt (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/common/services/retry/retry_for_success.js:39:21)
[00:08:20]                   │          at retryForSuccess (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/common/services/retry/retry_for_success.js:67:37)
[00:08:20]                   │ info Taking screenshot "/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/screenshots/failure/visualize app  point series custom labels and axis titles should preserve saved axis titles after a vis is saved and reopened.png"
[00:08:20]                   │ info Current URL is: http://localhost:5620/app/kibana#/visualize/edit/d8d839c0-0ea6-11e9-8c08-59b2d8f49780?_g=()&_a=(filters:!(),linked:!f,query:(language:lucene,query:%27%27),uiState:(),vis:(aggs:!((enabled:!t,id:%271%27,params:(customLabel:myLabel,field:bytes),schema:metric,type:avg)),params:(addLegend:!t,addTimeMarker:!f,addTooltip:!t,categoryAxes:!((id:CategoryAxis-1,labels:(show:!t,truncate:100),position:bottom,scale:(type:linear),show:!t,style:(),title:(),type:category)),grid:(categoryLines:!f,style:(color:%23eee)),legendPosition:right,seriesParams:!((data:(id:%271%27,label:myLabel),drawLinesBetweenPoints:!t,mode:normal,show:true,showCircles:!t,type:line,valueAxis:ValueAxis-1)),times:!(),type:line,valueAxes:!((id:ValueAxis-1,labels:(filter:!f,rotate:0,show:!t,truncate:100),name:LeftAxis-1,position:left,scale:(mode:normal,type:linear),show:!t,style:(),title:(text:myTitle),type:value))),title:%27Visualization%20Point%20Series%20Test%27,type:line))
[00:08:20]                   │ info Browser output is: http://localhost:5620/bundles/kibana.bundle.js 106759:49 Uncaught TypeError: Cannot read property 'join' of undefined
[00:08:20]                   │      http://localhost:5620/bundles/kibana.bundle.js 106759:49 Uncaught TypeError: Cannot read property 'join' of undefined
[00:08:20]                   │
[00:08:20]                   │ info Saving page source to: /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/failure_debug/html/visualize app  point series custom labels and axis titles should preserve saved axis titles after a vis is saved and reopened.html
[00:08:20]                   └- ✖ fail: "visualize app  point series custom labels and axis titles should preserve saved axis titles after a vis is saved and reopened"
[00:08:20]                   │      retry.try timeout: Error: retry.try timeout: [POST http://localhost:9515/session/499272fe6307c6d90e89f802eebcaf0f/element / {"using":"partial link text","value":"Visualization Point Series Test"}] no such element: Unable to locate element: {"method":"partial link text","selector":"Visualization Point Series Test"}
[00:08:20]                   │   (Session info: headless chrome=71.0.3578.98)
[00:08:20]                   │   (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 3.10.0-957.1.3.el7.x86_64 x86_64)
[00:08:20]                   │     at Server._post (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/services/remote/verbose_remote_logging.js:34:21)
[00:08:20]                   │     at runRequest (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:92:40)
[00:08:20]                   │     at /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:113:39
[00:08:20]                   │     at new Promise (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/Promise.ts:411:4)
[00:08:20]                   │     at Session._post (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:67:10)
[00:08:20]                   │     at Session.find (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Session.js:1328:15)
[00:08:20]                   │     at Command.<anonymous> (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Command.js:42:36)
[00:08:20]                   │     at /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/Promise.ts:393:16
[00:08:20]                   │     at run (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/Promise.ts:237:8)
[00:08:20]                   │     at /var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/dojo/_debug/nextTick.ts:44:4
[00:08:20]                   │     at process._tickCallback (internal/process/next_tick.js:61:11)
[00:08:20]                   │     at Command.find (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/Command.js:23:10)
[00:08:20]                   │     at Command.prototype.(anonymous function) [as findByPartialLinkText] (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/node_modules/leadfoot/lib/strategies.js:29:16)
[00:08:20]                   │     at _ensureElementWithTimeout (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/services/find.js:203:36)
[00:08:20]                   │     at retry.try (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/functional/services/find.js:76:33)
[00:08:20]                   │     at runAttempt (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/common/services/retry/retry_for_success.js:39:21)
[00:08:20]                   │     at retryForSuccess (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/common/services/retry/retry_for_success.js:67:37)
[00:08:20]                   │     at lastError (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/common/services/retry/retry_for_success.js:29:9)
[00:08:20]                   │     at retryForSuccess (/var/lib/jenkins/workspace/elastic+kibana+master/JOB/kibana-ciGroup11/node/immutable/kibana/test/common/services/retry/retry_for_success.js:63:13)
[00:08:20]                   │   Error: retry.try timeout: Error: retry.try timeout: [POST http://localhost:9515/session/499272fe6307c6d90e89f802eebcaf0f/element / {"using":"partial link text","value":"Visualization Point Series Test"}] no such element: Unable to locate element: {"method":"partial link text","selector":"Visualization Point Series Test"}
[00:08:20]                   │     (Session info: headless chrome=71.0.3578.98)
[00:08:20]                   │     (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 3.10.0-957.1.3.el7.x86_64 x86_64)
[00:08:20]                   │       at Server._post (test/functional/services/remote/verbose_remote_logging.js:34:21)
[00:08:20]                   │       at runRequest (node_modules/leadfoot/Session.js:92:40)
[00:08:20]                   │       at node_modules/leadfoot/Session.js:113:39
[00:08:20]                   │       at new Promise (node_modules/dojo/_debug/Promise.ts:411:4)
[00:08:20]                   │       at Session._post (node_modules/leadfoot/Session.js:67:10)
[00:08:20]                   │       at Session.find (node_modules/leadfoot/Session.js:1328:15)
[00:08:20]                   │       at Command.<anonymous> (node_modules/leadfoot/Command.js:42:36)
[00:08:20]                   │       at node_modules/dojo/_debug/Promise.ts:393:16
[00:08:20]                   │       at run (node_modules/dojo/_debug/Promise.ts:237:8)
[00:08:20]                   │       at node_modules/dojo/_debug/nextTick.ts:44:4
[00:08:20]                   │       at process._tickCallback (internal/process/next_tick.js:61:11)
[00:08:20]                   │       at Command.find (node_modules/leadfoot/Command.js:23:10)
[00:08:20]                   │       at Command.prototype.(anonymous function) [as findByPartialLinkText] (node_modules/leadfoot/lib/strategies.js:29:16)
[00:08:20]                   │       at _ensureElementWithTimeout (test/functional/services/find.js:203:36)
[00:08:20]                   │       at retry.try (test/functional/services/find.js:76:33)
[00:08:20]                   │       at runAttempt (test/common/services/retry/retry_for_success.js:39:21)
[00:08:20]                   │       at retryForSuccess (test/common/services/retry/retry_for_success.js:67:37)
[00:08:20]                   │       at lastError (test/common/services/retry/retry_for_success.js:29:9)
[00:08:20]                   │       at retryForSuccess (test/common/services/retry/retry_for_success.js:63:13)
[00:08:20]                   │       at lastError (test/common/services/retry/retry_for_success.js:29:9)
[00:08:20]                   │       at retryForSuccess (test/common/services/retry/retry_for_success.js:63:13)
[00:08:20]                   │ 
[00:08:20]                   │ 

@stacey-gammon
Copy link
Contributor

Screenshot:

screen shot 2019-01-08 at 10 57 49 am

Html:

Visualization Point Series Test - Kibana.htm.zip

@lukeelmers
Copy link
Member

I haven't been able to reproduce this failure when running tests locally, but I do have some suspicions about what's causing it:

  • The logs & screenshot indicate the retry failure is occurring on /app/kibana#/visualize/edit
  • I would expect this timeout to occur on /app/kibana#/visualize, where it can actually find the saved vis
  • This suggests to me that after the vis is being saved in the flaky test, navigation to /app/kibana#/visualize it not completing before attempting to find the vis by name, resulting in the Unable to locate element errors from the logs (since we aren't even on the page where the element exists)

I noticed that usually after we save a vis, we typically call waitForVisualizationSavedToastGone(), which was not added in this test.

So I opened #28272 to add that change and run CI a few times to see if it helps. So far that test has had no failures, but without being able to reliably reproduce, I'm sort of flying blind and I'm not 100% confident that we can officially mark this as resolved. More info in the PR.

@stacey-gammon
Copy link
Contributor

It looks like this might be what Tim was referring to in this issue that I closed yesterday: #19750 . "Fails to navigate".

This is what I think is going on. When you save a new visualization the url actually changes. It looks like a soft reload, not a hard reload, but I wonder if in that routing the link won't work if you click it at a certain time. Maybe if we changed

    async clickLoadSavedVisButton() {
      // TODO: Use a test subject selector once we rewrite breadcrumbs to accept each breadcrumb
      // element as a child instead of building the breadcrumbs dynamically.
      await find.clickByCssSelector('[href="#/visualize"]');
    }

to use await find.clickByCssSelectorWhenNotDisable('[href="#/visualize"]'); it would solve the problem? I'm not entirely sure though because it might not actually be "disabled" so much as the click dropped.

I'd suggest doing what dashboard does too, and add the "expect" part. This will at least be a better error message, so we actually see that the real problem is that the navigation failed to occur.

    async expectExistsDashboardLandingPage() {
      log.debug(`expectExistsDashboardLandingPage`);
      await testSubjects.existOrFail('dashboardLandingPage');
    }

    async clickDashboardBreadcrumbLink() {
      log.debug('clickDashboardBreadcrumbLink');
      await find.clickByCssSelector(`a[href="#${DashboardConstants.LANDING_PAGE_PATH}"]`);
      await this.expectExistsDashboardLandingPage();
    }

Even dashboard isn't using the clickByCssSelectorWhenNotDisabled version, maybe should if this is the real issue. I bet dashboard doesn't see this because it has:

    /**
     * Returns true if already on the dashboard landing page (that page doesn't have a link to itself).
     * @returns {Promise<boolean>}
     */
    async onDashboardLandingPage() {
      log.debug(`onDashboardLandingPage`);
      return await testSubjects.exists('dashboardLandingPage', 5000);
    }
    async gotoDashboardLandingPage() {
      log.debug('gotoDashboardLandingPage');
      const onPage = await this.onDashboardLandingPage();
      if (!onPage) {
        await this.clickDashboardBreadcrumbLink();
      }
    }

That check to see if the user is on the landing page waits up to 5 seconds to finally return false, so it's like adding in a 5 second sleep. This probably ensure the dashboard breadcrumb link is clickable by the time we get there. So @lukeelmers - your solution to wait for the toast to go away would probably solve it, but in a very subtle way. I think we should try to put the fix inside either loadSavedVisualization or clickLoadSavedVisButton that way anyone calling them will have the fix too (and given the git issue above, this flakiness probably rears its head in various tests.)

@lukeelmers
Copy link
Member

Thanks for the advice @stacey-gammon - Waiting for the toast to go away felt like an icky "fix" to me too. The clickByCssSelectorWhenNotDisabled idea makes a lot of sense... One thing I had noticed was that the nav button is not clickable when the "save vis" modal is open. I was thinking perhaps the click was happening before the modal was actually gone, as sometimes the "success" toast (which we wait to appear before proceeding) will pop up and overlap with the modal briefly.

I went ahead and pushed an update to the PR based on your suggestions... I'll re-run CI a couple times to see how it looks.

Still not able to reproduce locally, but either way this feels as if it is moving in a better direction!

@liza-mae
Copy link
Contributor Author

This test is still failing over last seven days on 6.6 and 6.x branches.

@lukeelmers
Copy link
Member

The PR that's in progress for this stalled last week after a couple of failed attempts -- will revisit again this week to see if I can sort anything out.

@cuff-links
Copy link
Contributor

This test is fixed in #31446. Waiting for it to merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
failed-test A test failure on a tracked branch, potentially flaky-test high Team:Visualizations Visualization editors, elastic-charts and infrastructure test_ui_functional test
Projects
None yet
Development

No branches or pull requests

5 participants