Final (?) de-widgetification

This commit is contained in:
2021-09-07 14:33:48 +00:00
parent 195edf7791
commit db8eafb1c0
22 changed files with 44 additions and 1062 deletions

View File

@@ -3,8 +3,8 @@
// const { WatchIgnorePlugin } = require("webpack");
//https://docs.cypress.io/guides/references/assertions.html#BDD-Assertions
describe("WIDGET FORM", () => {
it("Performs all crud ops on widget successfully", () => {
describe("customer FORM", () => {
it("Performs all crud ops on customer successfully", () => {
let unique = new Date().getTime();
cy.visit("/login");
cy.get("input[name=username]")
@@ -19,8 +19,8 @@ describe("WIDGET FORM", () => {
cy.url().should("include", "/ay-evaluate");
//POST
cy.visit("/widgets/0");
cy.url().should("include", "/widgets/0");
cy.visit("/customers/0");
cy.url().should("include", "/customers/0");
//cy.wait(5000);
//save the start url for later
@@ -69,20 +69,20 @@ describe("WIDGET FORM", () => {
force: true
}); //esc necessary to close tags control
cy.get(
"[data-cy=WidgetCustom2]"
"[data-cy=customerCustom2]"
).type("Custom text field testing a...b...c...{enter}EOT", { force: true });
//GET ROUTE
//SAve the record and ensure it's different
cy.get('[data-cy="widget-edit:save"]').click();
cy.url().should("include", "/widgets");
cy.get('[data-cy="customer-edit:save"]').click();
cy.url().should("include", "/customers");
cy.get("[data-cy=serial]").should("not.have.value", 0); //server sets new value on save
//PUT
cy.get("[data-cy=count]").type("321", { force: true });
cy.get('[data-cy="widget-edit:save"]').click({ force: true });
cy.get('[data-cy="customer-edit:save"]').click({ force: true });
//now get it back again and confirm settings
@@ -91,7 +91,7 @@ describe("WIDGET FORM", () => {
//delete the record
cy.get("[data-cy=contextmenu]").click();
cy.get('[data-cy="widget-edit:delete"]').click();
cy.get('[data-cy="customer-edit:delete"]').click();
cy.get('[data-cy="gzconfirm:yesbutton"]').click();
// //LOGOUT