|
|
@ -9,20 +9,19 @@ export const genTest = (apiType, dbType) => { |
|
|
|
before(() => { |
|
|
|
before(() => { |
|
|
|
loginPage.loginAndOpenProject(apiType, dbType); |
|
|
|
loginPage.loginAndOpenProject(apiType, dbType); |
|
|
|
cy.openTableTab("Country", 25); |
|
|
|
cy.openTableTab("Country", 25); |
|
|
|
cy.wait(1000); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cy.saveLocalStorage(); |
|
|
|
cy.saveLocalStorage(); |
|
|
|
cy.wait(1000); |
|
|
|
|
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
beforeEach(() => { |
|
|
|
beforeEach(() => { |
|
|
|
cy.restoreLocalStorage(); |
|
|
|
cy.restoreLocalStorage(); |
|
|
|
cy.wait(1000); |
|
|
|
}) |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
afterEach(() => { |
|
|
|
|
|
|
|
cy.saveLocalStorage(); |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
after(() => { |
|
|
|
after(() => { |
|
|
|
cy.restoreLocalStorage(); |
|
|
|
cy.restoreLocalStorage(); |
|
|
|
cy.wait(1000); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// clean up
|
|
|
|
// clean up
|
|
|
|
mainPage.deleteColumn("testAttach"); |
|
|
|
mainPage.deleteColumn("testAttach"); |
|
|
@ -44,6 +43,7 @@ export const genTest = (apiType, dbType) => { |
|
|
|
cy.getActiveMenu(".nc-dropdown-grid-context-menu").contains("Delete Row").click(); |
|
|
|
cy.getActiveMenu(".nc-dropdown-grid-context-menu").contains("Delete Row").click(); |
|
|
|
|
|
|
|
|
|
|
|
cy.closeTableTab("Country"); |
|
|
|
cy.closeTableTab("Country"); |
|
|
|
|
|
|
|
cy.saveLocalStorage(); |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
it(`Add column of type attachments`, () => { |
|
|
|
it(`Add column of type attachments`, () => { |
|
|
@ -62,9 +62,8 @@ export const genTest = (apiType, dbType) => { |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
it(`Form view with Attachment field- Submit & verify`, () => { |
|
|
|
it(`Form view with Attachment field- Submit & verify`, () => { |
|
|
|
|
|
|
|
// // open right navbar
|
|
|
|
// open right navbar
|
|
|
|
// cy.get('.nc-toggle-right-navbar').should('exist').click();
|
|
|
|
cy.get('.nc-toggle-right-navbar').should('exist').click(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// create form-view
|
|
|
|
// create form-view
|
|
|
|
cy.get(`.nc-create-form-view`).click(); |
|
|
|
cy.get(`.nc-create-form-view`).click(); |
|
|
@ -85,6 +84,8 @@ export const genTest = (apiType, dbType) => { |
|
|
|
let linkText = $obj.text().trim(); |
|
|
|
let linkText = $obj.text().trim(); |
|
|
|
cy.log(linkText); |
|
|
|
cy.log(linkText); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cy.signOut(); |
|
|
|
|
|
|
|
|
|
|
|
cy.visit(linkText, { |
|
|
|
cy.visit(linkText, { |
|
|
|
baseUrl: null, |
|
|
|
baseUrl: null, |
|
|
|
}); |
|
|
|
}); |
|
|
@ -101,7 +102,6 @@ export const genTest = (apiType, dbType) => { |
|
|
|
cy.get('.ant-picker-dropdown').find(".ant-picker-now-btn").click(); |
|
|
|
cy.get('.ant-picker-dropdown').find(".ant-picker-now-btn").click(); |
|
|
|
cy.get('.ant-picker-dropdown').find("button.ant-btn-primary").click(); |
|
|
|
cy.get('.ant-picker-dropdown').find("button.ant-btn-primary").click(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cy.get('.nc-attachment-cell') |
|
|
|
cy.get('.nc-attachment-cell') |
|
|
|
.attachFile(`sampleFiles/1.json`, { subjectType: 'drag-n-drop' }); |
|
|
|
.attachFile(`sampleFiles/1.json`, { subjectType: 'drag-n-drop' }); |
|
|
|
|
|
|
|
|
|
|
@ -117,11 +117,11 @@ export const genTest = (apiType, dbType) => { |
|
|
|
|
|
|
|
|
|
|
|
it(`Filter column which contain only attachments, download CSV`, () => { |
|
|
|
it(`Filter column which contain only attachments, download CSV`, () => { |
|
|
|
// come back to main window
|
|
|
|
// come back to main window
|
|
|
|
// loginPage.loginAndOpenProject(apiType, dbType);
|
|
|
|
loginPage.loginAndOpenProject(apiType, dbType); |
|
|
|
cy.visit('/') |
|
|
|
// cy.visit('/')
|
|
|
|
cy.wait(5000) |
|
|
|
// cy.wait(5000)
|
|
|
|
|
|
|
|
// projectsPage.openConfiguredProject(apiType, dbType);
|
|
|
|
|
|
|
|
|
|
|
|
projectsPage.openConfiguredProject(apiType, dbType); |
|
|
|
|
|
|
|
cy.openTableTab("Country", 25); |
|
|
|
cy.openTableTab("Country", 25); |
|
|
|
cy.wait(1000); |
|
|
|
cy.wait(1000); |
|
|
|
|
|
|
|
|
|
|
|