[ML] Docs screenshots - fix weblogs anomaly explorer screenshot (#125501)

This PR fixes the weblogs anomaly explorer docs screenshot by expanding the cell selection to the last element of the array and using another scrollIntoView.
This commit is contained in:
Robert Oskamp 2022-02-14 17:28:26 +01:00 committed by GitHub
parent cc74733a8b
commit 91314e0942
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -266,7 +266,7 @@ export default function ({ getPageObject, getService }: FtrProviderContext) {
await ml.testExecution.logTestStep('select swim lane tile');
const cells = await ml.swimLane.getCells(overallSwimLaneTestSubj);
const sampleCell1 = cells[11];
const sampleCell2 = cells[12];
const sampleCell2 = cells[cells.length - 1];
await ml.swimLane.selectCells(overallSwimLaneTestSubj, {
x1: sampleCell1.x + cellSize,
y1: sampleCell1.y + cellSize,
@ -281,6 +281,7 @@ export default function ({ getPageObject, getService }: FtrProviderContext) {
// clickFitToData only works with displayed legend
await maps.openLegend();
await maps.clickFitToData();
await ml.anomalyExplorer.scrollChartsContainerIntoView();
await maps.closeLegend();
await mlScreenshots.takeScreenshot(