diff --git a/test/functional/apps/dashboard/dashboard_filtering.js b/test/functional/apps/dashboard/dashboard_filtering.js index 1cb9f1490d442..cec6822be47e8 100644 --- a/test/functional/apps/dashboard/dashboard_filtering.js +++ b/test/functional/apps/dashboard/dashboard_filtering.js @@ -58,6 +58,11 @@ export default function({ getService, getPageObjects }) { await dashboardAddPanel.closeAddPanel(); + await PageObjects.header.waitUntilLoadingHasFinished(); + await PageObjects.dashboard.waitForRenderComplete(); + + await PageObjects.dashboard.saveDashboard('filtering test'); + await PageObjects.header.waitUntilLoadingHasFinished(); await PageObjects.dashboard.waitForRenderComplete(); await filterBar.addFilter('bytes', 'is', '12345678'); @@ -115,7 +120,24 @@ export default function({ getService, getPageObjects }) { }); }); - describe('using a pinned filter that excludes all data', () => { + // This is for a specific bug that wasn't caught by our existing tests. + describe('same filter can be re-applied after opening the dashboard back up', async () => { + before(async () => { + await PageObjects.dashboard.loadSavedDashboard('filtering test'); + + await PageObjects.header.waitUntilLoadingHasFinished(); + await PageObjects.dashboard.waitForRenderComplete(); + await filterBar.addFilter('bytes', 'is', '12345678'); + await PageObjects.header.waitUntilLoadingHasFinished(); + await PageObjects.dashboard.waitForRenderComplete(); + }); + + it('filters on pie charts', async () => { + await pieChart.expectPieSliceCount(0); + }); + }); + + describe('using a pinned filter that excludes all data', async () => { before(async () => { await filterBar.toggleFilterPinned('bytes'); await PageObjects.header.waitUntilLoadingHasFinished();