-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[7.x] move apps lower in tree, add metricbeat dashboard screenshot te…
- Loading branch information
Lee Drengenberg
authored
Oct 27, 2020
1 parent
bc629f6
commit a2b4067
Showing
31 changed files
with
81 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
59 changes: 59 additions & 0 deletions
59
x-pack/test/stack_functional_integration/apps/metricbeat/_metricbeat_dashboard.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License; | ||
* you may not use this file except in compliance with the Elastic License. | ||
*/ | ||
|
||
import expect from '@kbn/expect'; | ||
import { REPO_ROOT } from '@kbn/dev-utils'; | ||
|
||
export default function ({ getService, getPageObjects, updateBaselines }) { | ||
const screenshot = getService('screenshots'); | ||
const browser = getService('browser'); | ||
const esArchiver = getService('esArchiver'); | ||
const PageObjects = getPageObjects(['common', 'dashboard', 'timePicker']); | ||
|
||
describe('check metricbeat Dashboard', function () { | ||
before(async function () { | ||
await esArchiver.load(`${REPO_ROOT}/../integration-test/test/es_archives/metricbeat`); | ||
|
||
// this navigateToActualURL takes the place of navigating to the dashboard landing page, | ||
// filtering on the dashboard name, selecting it, setting the timepicker, and going to full screen | ||
await PageObjects.common.navigateToActualUrl( | ||
'dashboard', | ||
'view/Metricbeat-system-overview-ecs?_g=(filters:!(),refreshInterval:(pause:!t,value:0),' + | ||
'time:(from:%272020-09-29T19:02:37.902Z%27,to:%272020-09-29T19:06:43.218Z%27))&_a=' + | ||
'(description:%27Overview%20of%20system%20metrics%27,filters:!(),fullScreenMode:!t,' + | ||
'options:(darkTheme:!f),query:(language:kuery,query:%27%27),timeRestore:!f,' + | ||
'title:%27%5BMetricbeat%20System%5D%20Overview%20ECS%27,viewMode:view)', | ||
{ | ||
ensureCurrentUrl: false, | ||
shouldLoginIfPrompted: true, | ||
} | ||
); | ||
// await PageObjects.common.navigateToApp('dashboard', { insertTimestamp: false }); | ||
// await PageObjects.dashboard.loadSavedDashboard('[Metricbeat System] Overview ECS'); | ||
// await PageObjects.timePicker.setAbsoluteRange( | ||
// 'Sep 29, 2020 @ 14:02:37.902', | ||
// 'Sep 29, 2020 @ 14:06:43.218' | ||
// ); | ||
// await PageObjects.dashboard.clickFullScreenMode(); | ||
|
||
await PageObjects.common.sleep(2000); | ||
await PageObjects.dashboard.waitForRenderComplete(); | ||
await browser.setScreenshotSize(1000, 1000); | ||
}); | ||
|
||
it('[Metricbeat System] Overview ECS should match snapshot', async function () { | ||
try { | ||
const percentDifference = await screenshot.compareAgainstBaseline( | ||
'metricbeat_dashboard', | ||
updateBaselines | ||
); | ||
expect(percentDifference).to.be.lessThan(0.01); | ||
} finally { | ||
await PageObjects.dashboard.clickExitFullScreenLogoButton(); | ||
} | ||
}); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters