You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

69 lines
2.3 KiB

  1. describe("Connected Mode", function() {
  2. it("can save a password profile on connected mode", function() {
  3. cy.visit("/");
  4. cy.wait(500);
  5. cy.get(".fa-sign-in").click();
  6. cy.get("#email").type("test@lesspass.com");
  7. cy.get("#passwordField").type("test@lesspass.com");
  8. cy.get("#fingerprint .fa-cutlery").should("be.visible");
  9. cy.get("#fingerprint .fa-subway").should("be.visible");
  10. cy.get("#fingerprint .fa-plane").should("be.visible");
  11. cy.get("#signInButton").click();
  12. cy.wait(500);
  13. cy.get("#siteField").type("lesspass.com");
  14. cy.get("#login").type("test@lesspass.com");
  15. cy.get("#passwordField").type("test@lesspass.com");
  16. cy.get("#generatePassword__btn").click();
  17. cy.get("#generated-password").should("have.value", "hjV@\\5ULp3bIs,6B");
  18. cy.get(".fa-save").should("be.visible");
  19. cy.get(".fa-user")
  20. .first()
  21. .click();
  22. cy.get("#signOutButton").should("be.visible");
  23. cy.get("#signOutButton").click();
  24. cy.get(".fa-save").should("not.exist");
  25. });
  26. it("can log in and log out", function() {
  27. cy.visit("/");
  28. cy.wait(500);
  29. cy.get(".fa-sign-in").click();
  30. cy.get("#email").type("test@lesspass.com");
  31. cy.get("#passwordField").type("test@lesspass.com");
  32. cy.wait(1000);
  33. cy.get("#signInButton").click();
  34. cy.get("#siteField").should("be.visible");
  35. cy.get(".fa-key").should("be.visible");
  36. cy.get(".fa-user")
  37. .first()
  38. .click();
  39. cy.get("#signOutButton").click();
  40. cy.get(".fa-key").should("not.exist");
  41. });
  42. it("reset password page", function() {
  43. cy.visit("/");
  44. cy.wait(500);
  45. cy.get(".fa-sign-in").click();
  46. cy.get("#login__forgot-password-btn").click();
  47. cy.get("#password-reset__reset-password-btn").click();
  48. });
  49. it("use saved profile", function() {
  50. cy.visit("/");
  51. cy.wait(500);
  52. cy.get(".fa-sign-in").click();
  53. cy.get("#email").type("test@lesspass.com");
  54. cy.get("#passwordField").type("test@lesspass.com");
  55. cy.wait(500);
  56. cy.get("#signInButton").click();
  57. cy.get(".fa-key").click();
  58. cy.get(".passwordProfile__meta")
  59. .first()
  60. .click();
  61. cy.get("#siteField").should("have.value", "example.org");
  62. cy.get("#login").should("have.value", "contact@example.org");
  63. cy.get(".fa-user")
  64. .first()
  65. .click();
  66. cy.get("#signOutButton").click();
  67. });
  68. });