1
0
Fork 0
mirror of synced 2024-08-10 15:41:24 +12:00

Updated commands.js

createScreen command now uses a specific data-cy id

also added 1 second wait within selectExternalDatasource - assists with timing for smoke build
This commit is contained in:
Mitch-Budibase 2022-04-26 15:56:11 +01:00
parent 5f963b2bfa
commit 2b2035b187

View file

@ -292,7 +292,7 @@ Cypress.Commands.add("createScreen", (route, accessLevelLabel) => {
cy.contains("Design").click()
cy.get("[aria-label=AddCircle]").click()
cy.get(".spectrum-Modal").within(() => {
cy.get(".item").contains("Blank screen").click()
cy.get("[data-cy='blank-screen']").click()
cy.get(".spectrum-Button").contains("Continue").click({ force: true })
cy.wait(500)
})
@ -473,6 +473,7 @@ Cypress.Commands.add("selectExternalDatasource", datasourceName => {
cy.get(".add-button").click()
})
// Clicks specified datasource & continue
cy.wait(1000)
cy.get(".item-list").contains(datasourceName).click()
cy.get(".spectrum-Dialog-grid").within(() => {
cy.get(".spectrum-Button").contains("Continue").click({ force: true })