1
0
Fork 0
mirror of synced 2024-07-04 14:01:27 +12:00

Adding delay to cypress test to allow time for statistics to calculate.

This commit is contained in:
mike12345567 2021-02-16 22:12:58 +00:00
parent 6d519e1ad9
commit 91926d17d9
2 changed files with 4 additions and 2 deletions

View file

@ -53,6 +53,7 @@ context("Create a View", () => {
cy.wait(50) cy.wait(50)
cy.get(".menu-container").find("select").eq(1).select("age") cy.get(".menu-container").find("select").eq(1).select("age")
cy.contains("Save").click() cy.contains("Save").click()
cy.wait(100)
cy.get(".ag-center-cols-viewport").scrollTo("100%") cy.get(".ag-center-cols-viewport").scrollTo("100%")
cy.get("[data-cy=table-header]").then($headers => { cy.get("[data-cy=table-header]").then($headers => {
expect($headers).to.have.length(7) expect($headers).to.have.length(7)
@ -65,7 +66,6 @@ context("Create a View", () => {
let values = Array.from($values).map(header => let values = Array.from($values).map(header =>
header.textContent.trim() header.textContent.trim()
) )
values = values.filter(value => value !== "")
expect(values).to.deep.eq([ '31', '5347', '5', '49', '20', '155', 'age' ]) expect(values).to.deep.eq([ '31', '5347', '5', '49', '20', '155', 'age' ])
}) })
}) })

View file

@ -30,7 +30,9 @@
Object.keys(viewTable.schema).filter( Object.keys(viewTable.schema).filter(
field => field =>
view.calculation === "count" || view.calculation === "count" ||
viewTable.schema[field].type === "number" // don't want to perform calculations based on auto ID
(viewTable.schema[field].type === "number" &&
!viewTable.schema[field].autocolumn)
) )
function saveView() { function saveView() {