1
0
Fork 0
mirror of synced 2024-06-30 12:00:31 +12:00

Merge pull request #7238 from Budibase/cypress-testing

Cypress: Smoke Build Changes
This commit is contained in:
Mitch-Budibase 2022-08-12 15:04:55 +01:00 committed by GitHub
commit a4e0f6617b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 3 deletions

View file

@ -2,7 +2,7 @@ import filterTests from "../support/filterTests"
const interact = require('../support/interact') const interact = require('../support/interact')
filterTests(['all'], () => { filterTests(['all'], () => {
context("Add Multi-Option Datatype", () => { xcontext("Add Multi-Option Datatype", () => {
before(() => { before(() => {
cy.login() cy.login()
cy.createTestApp() cy.createTestApp()

View file

@ -266,7 +266,7 @@ filterTests(["all"], () => {
cy.reload() cy.reload()
cy.log("Current deployment version: " + clientPackage.version) cy.log("Current deployment version: " + clientPackage.version)
cy.get(".version-status a", { timeout: 1000 }).contains("Update").click() cy.get(".version-status a", { timeout: 5000 }).contains("Update").click()
cy.get(".spectrum-Tabs-item.is-selected").contains("Settings") cy.get(".spectrum-Tabs-item.is-selected").contains("Settings")
cy.get(".version-section .page-action button") cy.get(".version-section .page-action button")

View file

@ -128,7 +128,9 @@ Cypress.Commands.add("updateUserInformation", (firstName, lastName) => {
.should("have.value", lastName) .should("have.value", lastName)
.blur() .blur()
} }
cy.get("button").contains("Update information").click({ force: true }) cy.get(".confirm-wrap").within(() => {
cy.get("button").contains("Update information").click({ force: true })
})
cy.get(".spectrum-Dialog-grid").should("not.exist") cy.get(".spectrum-Dialog-grid").should("not.exist")
}) })
}) })
@ -432,6 +434,7 @@ Cypress.Commands.add("createAppFromScratch", appName => {
// TABLES // TABLES
Cypress.Commands.add("createTable", (tableName, initialTable) => { Cypress.Commands.add("createTable", (tableName, initialTable) => {
// Creates an internal Budibase DB table
if (!initialTable) { if (!initialTable) {
cy.navigateToDataSection() cy.navigateToDataSection()
cy.get(`[data-cy="new-table"]`, { timeout: 2000 }).click() cy.get(`[data-cy="new-table"]`, { timeout: 2000 }).click()
@ -445,6 +448,10 @@ Cypress.Commands.add("createTable", (tableName, initialTable) => {
.contains("Continue") .contains("Continue")
.click({ force: true }) .click({ force: true })
}) })
cy.get(".spectrum-Modal", { timeout: 10000 }).should(
"not.contain",
"Add data source"
)
cy.get(".spectrum-Modal", { timeout: 2000 }).within(() => { cy.get(".spectrum-Modal", { timeout: 2000 }).within(() => {
cy.get("input", { timeout: 2000 }).first().type(tableName).blur() cy.get("input", { timeout: 2000 }).first().type(tableName).blur()
cy.get(".spectrum-ButtonGroup").contains("Create").click() cy.get(".spectrum-ButtonGroup").contains("Create").click()