diff --git a/cypress/e2e/desktop/menuNavigation.cy.js b/cypress/e2e/desktop/menuNavigation.cy.js index a659f8c2..bec13120 100644 --- a/cypress/e2e/desktop/menuNavigation.cy.js +++ b/cypress/e2e/desktop/menuNavigation.cy.js @@ -19,11 +19,18 @@ describe('menu navigation', () => { }); it('should successfully show the join team content', () => { - // TODO + // Click the join team sidebar button + cy.get('[data-cy=sidebar-jointeam-button]').click(); + + cy.get('[data-cy=jointeam-header]').should('have.text', 'Join the team'); }); - it('should successfully show the contact form and send feedback', () => { - // TODO - // Make form submission send to a test destination for validation + it('should successfully show the contact form', () => { + // Click the contact sidebar button + cy.get('[data-cy=sidebar-contact-button]').click(); + + // Verify the iframe is present + cy.get('iframe[title="Contact Us"]').should('exist'); + cy.get('iframe[title="Contact Us"]').should('have.attr', 'src').and('include', 'airtable.com'); }); }); diff --git a/cypress/e2e/mobile/menuNavigation.cy.js b/cypress/e2e/mobile/menuNavigation.cy.js index 0f87311e..a7f37d15 100644 --- a/cypress/e2e/mobile/menuNavigation.cy.js +++ b/cypress/e2e/mobile/menuNavigation.cy.js @@ -9,15 +9,42 @@ describe("menu navigation", () => { }); it("should successfully show about us content", () => { - // TODO + cy.viewport('iphone-x'); + + // Click the hamburger menu button + cy.get('[data-cy=head-sidebar-button]').click(); + + // Click the "About" button + cy.get('[data-cy=sidebar-about-button]').click(); + + // Verify the header text displays "About PHLASK" + cy.get('[data-cy=about-header]').should('have.text', 'About PHLASK'); }); it("should successfully show the join team content", () => { - // TODO + cy.viewport('iphone-x'); + + // Click the hamburger menu button + cy.get('[data-cy=head-sidebar-button]').click(); + + // Click the "Join the team" button + cy.get('[data-cy=sidebar-jointeam-button]').click(); + + // Verify the header text displays "Join the team" + cy.get('[data-cy=jointeam-header]').should('have.text', 'Join the team'); }); - it("should successfully show the contact form and send feedback", () => { - // TODO - // Make form submission send to a test destination for validation + it("should successfully show the contact form", () => { + cy.viewport('iphone-x'); + + // Click the hamburger menu button + cy.get('[data-cy=head-sidebar-button]').click(); + + // Click the "Contact" button + cy.get('[data-cy=sidebar-contact-button]').click(); + + // Verify the iframe is present + cy.get('iframe[title="Contact Us"]').should('exist'); + cy.get('iframe[title="Contact Us"]').should('have.attr', 'src').and('include', 'airtable.com'); }); });