Skip to content

Commit 2d5dee7

Browse files
committed
✅ Create test for validation of page Forgot
1 parent c20d0be commit 2d5dee7

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
describe("Page Forgot", function() {
2+
it("Verify if exist the field E-mail", function() {
3+
cy.visit("/auth/forgot");
4+
5+
cy.contains("E-mail:");
6+
cy.get("input[name=email]");
7+
});
8+
9+
it("Send form without filling in the inputs", function() {
10+
cy.visit("/auth/forgot");
11+
cy.contains("Enviar").click();
12+
13+
cy.contains("E-mail é obrigatório");
14+
});
15+
16+
it("Send form with email invalid", function() {
17+
cy.visit("/auth/forgot");
18+
cy.get("input[name=email]").type("empix");
19+
cy.contains("Enviar").click();
20+
cy.contains("Preencha com email válido");
21+
});
22+
23+
it("Send form with all fields valid", function() {
24+
cy.visit("/auth/forgot");
25+
cy.get("input[name=email]").type("any.email@gmail.com");
26+
cy.contains("Enviar").click();
27+
});
28+
});

0 commit comments

Comments
 (0)