This commit is contained in:
2021-12-21 00:01:47 +00:00
parent cee49ac0a7
commit 5160fe7d5f
5 changed files with 32 additions and 24 deletions

View File

@@ -63,9 +63,10 @@ Cypress.Commands.add("ayChooseExistingTags", (dataCyTag, tagList) => {
});
Cypress.Commands.add("aySetTestableUserOptions", () => {
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=home]").click();
cy.get("[data-cy='nav/home-user-settings']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy=home]").click();
// cy.get("[data-cy='nav/home-user-settings']").click();
cy.visit('/home-user-settings');
cy.url().should("include", "/home-user-settings");
cy.get("[data-cy='nativeDateTimeInput']").check({ force: true });
});

View File

@@ -1,5 +1,5 @@
/// <reference types="cypress" />
describe("When Accounting user logs in", () => {
describe.skip("When Accounting user logs in", () => {
it("should set up accounting block user options", () => {
cy.ayLogin("accounting");

View File

@@ -1,9 +1,9 @@
/// <reference types="cypress" />
describe("Search", () => {
it("should work", () => {
//SEARCH
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy='nav/home-search']").click();
cy.ayLogin("accounting");
cy.visit("/home-search");
cy.url().should("include", "/home-search");
cy.get("[data-cy=phrase]").clear().type("xyz{enter}");
//check for expected results

View File

@@ -15,9 +15,10 @@ describe("Reminder features", () => {
cy.ayLogin("accounting");
cy.aySetTestableUserOptions();
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=home]").click();
cy.get("[data-cy='nav/home-reminders']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy=home]").click();
// cy.get("[data-cy='nav/home-reminders']").click();
cy.visit("/home-reminders");
cy.url().should("include", "/home-reminders");
cy.get("[data-cy='reminder-list:new']:first").click();
cy.url().should("include", "/home-reminders/");
@@ -31,13 +32,15 @@ describe("Reminder features", () => {
cy.get("[data-cy=notes]").type(`This is a reminder{enter}eot{enter}`);
cy.get(".v-color-picker__input > input").clear().type("#11E1D07E{enter}"); //select a color
cy.get('[data-cy="reminder-edit:save"] > .v-btn__content').click();
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy='nav/home-reminders']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy='nav/home-reminders']").click();
cy.visit("/home-reminders");
cy.url().should("include", "/home-reminders");
//should show reminder made above in month display by default
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy='nav/home-schedule']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy='nav/home-schedule']").click();
cy.visit("/home-schedule");
cy.url().should("include", "/home-schedule");
cy.contains(`${Cypress.config("cyid")}-test-reminder`);
});

View File

@@ -16,9 +16,10 @@ describe("Contract create, review, history", () => {
cy.ayLogin("accounting");
cy.aySetTestableUserOptions();
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=accounting]").click();
cy.get("[data-cy='nav/svc-contracts']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy=accounting]").click();
// cy.get("[data-cy='nav/svc-contracts']").click();
cy.visit('/svc-contracts')
cy.url().should("include", "/svc-contracts");
cy.get("[data-cy=contractsTable]");
cy.get("[data-cy='contract-list:new']:first").click();
@@ -34,8 +35,9 @@ describe("Contract create, review, history", () => {
`Test contract alert message{enter}eot{enter}`
);
cy.get("[data-cy='contract-edit:save'] > .v-btn__content").click();
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy='nav/svc-contracts']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy='nav/svc-contracts']").click();
cy.visit('/svc-contracts')
cy.url().should("include", "/svc-contracts");
@@ -60,9 +62,10 @@ describe("Contract create, review, history", () => {
cy.contains(`${Cypress.config("cyid")}-test-review`);
cy.contains(`${Cypress.config("cyid")}-test-contract`);
//should show review made above in schedule
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy=home]").click();
cy.get("[data-cy='nav/home-schedule']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy=home]").click();
//cy.get("[data-cy='nav/home-schedule']").click();
cy.visit('/home-schedule')
cy.url().should("include", "/home-schedule");
cy.get(".v-present > .v-calendar-weekly__day-label > .v-btn").click({
force: true
@@ -71,8 +74,9 @@ describe("Contract create, review, history", () => {
cy.contains(`${Cypress.config("cyid")}-test-review`);
//HISTORY
cy.get("[data-cy=navicon]").click();
cy.get("[data-cy='nav/home-history']").click();
// cy.get("[data-cy=navicon]").click();
// cy.get("[data-cy='nav/home-history']").click();
cy.visit("/history");
cy.url().should("include", "/history");
cy.contains(`${Cypress.config("cyid")}-test-contract`);
cy.contains(`${Cypress.config("cyid")}-test-review`);