diff --git a/cypress/e2e/addFeedForm.cy.ts b/cypress/e2e/addFeedForm.cy.ts index c3163c2c..80af09bb 100644 --- a/cypress/e2e/addFeedForm.cy.ts +++ b/cypress/e2e/addFeedForm.cy.ts @@ -14,7 +14,7 @@ describe('Add Feed Form', () => { ); cy.get('[data-cy="accountHeader"]').should('exist'); // assures that the user is signed in - cy.visit('/contribute'); + cy.get('[data-cy="header-add-a-feed"]').click(); // Assures that the firebase remote config has loaded for the first test // Optimizations can be made to make the first test run faster // Long timeout is to assure no flakiness diff --git a/cypress/e2e/changepassword.cy.ts b/cypress/e2e/changepassword.cy.ts index 33dd24fd..0941f0a6 100644 --- a/cypress/e2e/changepassword.cy.ts +++ b/cypress/e2e/changepassword.cy.ts @@ -7,8 +7,9 @@ describe('Change Password Screen', () => { cy.visit('/'); cy.get('[data-testid="home-title"]').should('exist'); cy.createNewUserAndSignIn(email, currentPassword); - cy.get('[data-cy="accountHeader"]').should('exist'); // assures that the user is signed in - cy.visit('/change-password'); + cy.get('[data-cy="accountHeader"]').should('exist').click(); // assures that the user is signed in + cy.get('[data-cy="accountDetailsHeader"]').should('exist').click(); + cy.get('[data-cy="changePasswordButton"]').should('exist').click(); }); it('should render components', () => { @@ -51,7 +52,7 @@ describe('Change Password Screen', () => { // logout cy.get('[data-cy="signOutButton"]').click(); - cy.get('[data-cy="confirmSignOutButton"]').should('exist').click(); + cy.get('[data-cy="confirmSignOutButton"]').should('exist').should('not.be.disabled').click(); cy.visit('/sign-in'); cy.get('[data-cy="signInEmailInput"]').type(email); cy.get('[data-cy="signInPasswordInput"]').type(newPassword); diff --git a/docs/ssg-initial-flow.md b/docs/ssg-initial-flow.md new file mode 100644 index 00000000..c9b7065f --- /dev/null +++ b/docs/ssg-initial-flow.md @@ -0,0 +1,43 @@ +```mermaid +sequenceDiagram + autonumber + actor U as User + participant B as Browser + participant CDN as CDN/Edge Cache + participant Next as Next.js Build (CI) + participant I18N as next-intl (generateStaticParams) + participant RC as Firebase Remote Config (build-time) + participant JS as Client JS (Header component) + + rect rgb(235, 245, 255) + note over Next,RC: BUILD TIME (SSG) + Next->>I18N: generateStaticParams() → all locales + I18N-->>Next: locale list + Next->>I18N: Build locale message bundles (baked) + Next->>RC: Fetch Remote Config snapshot (baked) + RC-->>Next: Remote Config values + Next->>Next: Render pages to static HTML + Next->>Next: Extract critical MUI styles (Emotion) + note over Next: