Uploaded image for project: 'Planet4'
  1. Planet4
  2. PLANET-5284

Write an e2e test for password protected content

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Merged
    • Icon: Must have Must have
    • None
    • None
    • 5
    • Pages, Testing
    • Sprint #142
    • janus

      Summary

      Write a Playwright test to make sure password protected pages are not publicly displayed.

      Requirements

      • Add the test inside tests/e2e/ folder.
      • Use the editor to create content (not the API).

      Test steps

      1. Login to the Admin panel
      2. Navigate to Pages > Add New
      3. Add a Page title (eg. _"Private Page")
      4. On the sidebar change the visibility to Password protected and set a password
      5. Add a paragraph block with dummy text
      6. Publish the page
      7. Logout
      8. Navigate to the page frontend url
      9. Test that Page title and text are not displayed
      10. Password protection message should be displayed: "To see the content of this page, please enter your password below"
      11. Submit the password
      12. Test that title and text are displayed

            mleray Maud Leray
            nroussos Nikos Roussos
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: