Skip to content

Testing

Henri Sjöblom edited this page Nov 10, 2024 · 5 revisions

Testing strategy

Before creating a PR, the app will be tested manually and automatically before merging. We have a GitHub pipeline, that runs type-checks and runs automatic Playwright tests.

Tools

  • Playwright E2E tests
  • Hoppscotch and Postman.

Test cases

Test case 1

Authentication and authorization

Description

  • Errors are displayed when logging in / creating a new user
  • Validation works
  • User is redirected to logging in if enters a page that needs authorization

Steps to perform

  • Automated using Playwright.

Expected result

All cases in the description happen.

Test case 2

API endpoints security

Description

Check that user can only access their info on all routers.

Steps to perform

Create requests using Hoppscotch / Postman or alternative app

Expected result

User can only access their own information

Test case 3

Chat Page

Description

  • Verify the Chat page loads correctly.
  • Verify that a new thread can be created and a message can be sent.
  • Verify that a thread can be deleted.

Steps to perform

  • Automated using Playwright.

Expected result

All cases in the description happen.

Test case 4

Flash cards

Description

  • Creating new flashcards work
  • Flash cards can be played
  • Results are saved in db
  • History shows created flashcard
  • Flash card can be played from history
  • History can be deleted

Steps to perform

  • Automated using Playwright.

Expected result

All cases in the description happen.

Test case 5

Settings Page

Description

  • Verify name and email can be updated
  • Verify password can be changed
  • Verify default cards settings can be uptaded

Steps to perform

  • Automated using Playwright.

Expected result

All cases in the description happen.

Clone this wiki locally