coronasafe/care_fe

View on GitHub
cypress/support/commands.ts

Summary

Maintainability
B
4 hrs
Test Coverage

Showing 2 of 2 total issues

Similar blocks of code found in 2 locations. Consider refactoring.
Open

Cypress.Commands.add("clickCancelButton", (buttonText = "Cancel") => {
cy.get("#cancel").contains(buttonText).scrollIntoView();
cy.get("#cancel").contains(buttonText).click();
});
Severity: Major
Found in cypress/support/commands.ts and 1 other location - About 2 hrs to fix
cypress/support/commands.ts on lines 35..38

Similar blocks of code found in 2 locations. Consider refactoring.
Open

Cypress.Commands.add("clickSubmitButton", (buttonText = "Submit") => {
cy.get("button[type='submit']").contains(buttonText).scrollIntoView();
cy.get("button[type='submit']").contains(buttonText).click();
});
Severity: Major
Found in cypress/support/commands.ts and 1 other location - About 2 hrs to fix
cypress/support/commands.ts on lines 40..43
Category
Status