This commit is contained in:
2021-12-21 18:27:06 +00:00
parent 3644da98ad
commit f1814a16f8
2 changed files with 64 additions and 20 deletions

View File

@@ -6,10 +6,10 @@
"directories": {
"test": "tests"
},
"dependencies": {
"cypress": "^9.1.1"
"dependencies": {},
"devDependencies": {
"cypress": "^9.2.0"
},
"devDependencies": {},
"scripts": {
"open": "./node_modules/.bin/cypress open",
"all-chrome": "./node_modules/.bin/cypress run --browser chrome",

View File

@@ -1,27 +1,71 @@
// Basic smoke test, visit every form to ensure they load
// Basic nav and menu test just to confirm each section menu works
describe("SMOKE NAV", () => {
it("Nav and menu functions correctly", () => {
cy.ayLogin("admin");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=home]").click();
cy.get("[data-cy='nav/home-memos']").click();
cy.get("[data-cy='nav/home-dashboard']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
// cy.visit("/vendors");
// cy.url().should("include", "/vendors");
// cy.get("[data-cy=generalerror]").should("not.exist");
// cy.get("[data-cy=vendorsTable]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=customer]").click();
cy.get("[data-cy='nav/cust-head-offices']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=headofficesTable]");
// cy.visit("/vendors/1");
// cy.url().should("include", "vendors/1");
// cy.get("[data-cy=generalerror]").should("not.exist");
// cy.get("[data-cy=name]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=service]").click();
cy.get("[data-cy='nav/svc-projects']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=projectsTable]");
// //LOGOUT
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy=logout]").click();
// cy.url().should("include", "/login");
// cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=inventory]").click();
cy.get("[data-cy='nav/inv-part-warehouses']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=partwarehousesTable]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=vendor]").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=vendorsTable]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=accounting]").click();
cy.get("[data-cy='nav/acc-tax-codes']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=taxCodesTable]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=administration]").click();
cy.get("[data-cy='nav/adm-import']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=ayaType]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=operations]").click();
cy.get("[data-cy='nav/ops-jobs']").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=jobsTable]");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=evaluate]").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=btnSeed]");
cy.get("[data-cy=notification]").click();
cy.get("[data-cy=generalerror]").should("not.exist");
cy.get("[data-cy=notifications]");
cy.get("[data-cy=contextmenu]").click();
cy.get("[data-cy='app:help']")
cy.get("[data-cy='app:nav:abt']");
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=logout]").click();
cy.url().should("include", "/login");
cy.get("[data-cy=generalerror]").should("not.exist");
//-----------------------------------------------------
});