From b9b6cafb89a68eb440ecbcc76bb2b5c85d96edf0 Mon Sep 17 00:00:00 2001 From: "Grot (@grafanabot)" <43478413+grafanabot@users.noreply.github.com> Date: Mon, 5 Dec 2022 16:02:34 +0200 Subject: [PATCH] [v9.3.x] Package: @grafana/e2e updates (#59825) Package: @grafana/e2e updates (#59723) E2E package updates - Update addDashboard flow to work with latest grafana - Update viewport configuration to ensure components aren't hidden (cherry picked from commit b4cf711a7493d3e33baa5a314a0fd9afe82d2185) Co-authored-by: Andreas Christou --- packages/grafana-e2e/cypress.json | 4 +++- packages/grafana-e2e/src/flows/addDashboard.ts | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/grafana-e2e/cypress.json b/packages/grafana-e2e/cypress.json index eaa48eb162f..7eafaf4bf2b 100644 --- a/packages/grafana-e2e/cypress.json +++ b/packages/grafana-e2e/cypress.json @@ -1,5 +1,7 @@ { "projectId": "zb7k1c", "supportFile": "cypress/support/index.ts", - "videoCompression": 20 + "videoCompression": 20, + "viewportWidth": 1920, + "viewportHeight": 1080 } diff --git a/packages/grafana-e2e/src/flows/addDashboard.ts b/packages/grafana-e2e/src/flows/addDashboard.ts index 36dca49b86b..a8c02d8e1fe 100644 --- a/packages/grafana-e2e/src/flows/addDashboard.ts +++ b/packages/grafana-e2e/src/flows/addDashboard.ts @@ -236,9 +236,9 @@ const addVariable = (config: PartialAddVariableConfig, isFirst: boolean): AddVar e2e.pages.Dashboard.Settings.Variables.Edit.General.generalTypeSelectV2() .should('be.visible') .within(() => { - e2e.components.Select.singleValue().should('have.text', 'Query').click(); + e2e.components.Select.singleValue().should('have.text', 'Query').parent().click(); }); - e2e.components.Select.option().should('be.visible').contains(type).click(); + e2e.pages.Dashboard.Settings.Variables.Edit.General.generalTypeSelectV2().find('input').type(`${type}{enter}`); } if (label) {