Skip to Content
FrontendAppsAccountTest Cases

Test Cases

Test Case 1.1: Display Account Information

Objective Ensure account information (ID, username, email) is correctly displayed to the user.

Test Steps

  1. Login as a valid user.
  2. Navigate to the account detail page.
  3. Verify visibility of ID, Username, and Email.

Expected Results

  • All fields (ID, Username, Email) are visible and non-editable by default.

Test Case 2.1: Edit Account Information

Objective Ensure the user can update their account information using the “Edit” button.

Test Steps

  1. Login and go to the account page.
  2. Click the “Edit” button.
  3. Enter the right password.
  4. Change the Username or Email.
  5. Click “Save”.
  6. Reload the page to confirm changes persist.

Expected Results

  • New values are saved and shown after reload.
  • Success message is shown on update.
  • The password works.

Test Case 2.2: Edit Account Information failure

Objective Ensure the password protection for editing user information works.

Test Steps

  1. Login and go to the account page.
  2. Click the “Edit” button.
  3. Enter a wrong password.
  4. Change the Username or Email.
  5. Click “Save”.
  6. Reload the page to confirm changes did not happen.

Expected Results

  • New values are not saved after reload.
  • Error message is shown.
  • The validation is working.

Test Case 3.1: Change Password

Objective Ensure that users can successfully change their password when all inputs are valid.

Test Steps

  1. Go to the account page.
  2. Click the “Change Password” button.
  3. Enter the correct current password, a strong new password, and match it in confirm new password.
  4. Submit the form.

Expected Results

  • Password strength requirements are enforced.
  • Success message is displayed.
  • Login with the old password fails; new password succeeds.

Test Case 3.2: Change Password - Confirmation Field Mismatch

Objective Ensure the system detects when the new password and confirmation do not match.

Test Steps

  1. Go to the account page.
  2. Click the “Change Password” button.
  3. Enter the correct current password, a new password, and a different confirm new password.
  4. Submit the form.

Expected Results

  • Password strength requirements are checked.
  • Error message is shown due to mismatched confirmation.
  • Password is not changed.
  • Login with the old password still works.

Test Case 3.3: Change Password - Incorrect Current Password

Objective Ensure the system rejects password changes when the current password is incorrect.

Test Steps

  1. Go to the account page.
  2. Click the “Change Password” button.
  3. Enter an incorrect current password, a valid new password, and matching confirm new password.
  4. Submit the form.

Expected Results

  • Password strength requirements are checked.
  • Error message is displayed due to incorrect current password.
  • Password is not changed.
  • Login with the old password still works.

Test Case 4.1: Update Account Preferences Successfully

Objective Ensure user preferences can be updated and persist correctly across sessions.

Test Steps

  1. Navigate to the account preferences page.
  2. Change one or more settings (e.g., enable dark mode, change language to French).
  3. Click “Save Preferences”.
  4. Reload the page or log out and back in to confirm preferences are retained.

Expected Results

  • Updated preferences are applied immediately.
  • Changes persist across sessions and reloads.
  • Valid values are accepted and saved successfully.

Test Case 4.2: Update Account Preferences with Empty Values

Objective Ensure the system does not accept empty or invalid preference inputs.

Test Steps

  1. Navigate to the account preferences page.
  2. Clear a required field or leave a preference setting empty.
  3. Click “Save Preferences”.

Expected Results

  • System displays a validation error for empty or invalid input.
  • Preferences are not saved.
  • No changes are applied to user settings.
  • Previously saved preferences remain unchanged.

Test Case 4.3: Update Only Non-Empty Preferences

Objective Ensure that only non-empty, valid preferences are updated and others remain unchanged.

Test Steps

  1. Navigate to the account preferences page.
  2. Change one preference (e.g., language), leave other fields empty or unchanged.
  3. Click “Save Preferences”.
  4. Reload and confirm that only the modified field was updated.

Expected Results

  • Only the changed, valid preference is updated.
  • Unchanged preferences retain their previous values.
  • No validation errors occur for untouched or empty optional fields.

Test Case 5.1: Multi-Factor Authentication (MFA) Setup

Objective Verify MFA setup, toggling, and error handling.

Test Steps

  1. Go to the MFA settings page.
  2. Enable MFA (e.g., QR code + secret key).
  3. Enter the verification code.
  4. Confirm activation.
  5. Try login with and without MFA to validate flow.

Expected Results

  • MFA is enabled with valid input.
  • Incorrect codes are rejected.
  • Login flow requires MFA if enabled.
  • MFA can be disabled securely.

Test Case 6.1: 404 Error Page

Objective Ensure that invalid or unknown account URLs display a friendly 404 page.

Test Steps

  1. Visit a non-existent account page (/account/unknown).
  2. Wait for the response.

Expected Results

  • A 404 error page is shown.
  • User is offered navigation back to a safe page.

Test Case 7.1: Account Error Page

Objective Verify that errors (e.g., server-side issues) in the account module are handled with a proper error page.

Test Steps

  1. Simulate a backend error on the account page (e.g., by removing auth token).
  2. Reload the page.

Expected Results

  • A dedicated error page is shown with messaging (e.g., “Account Error”).
  • User is not left on a broken or blank screen.
  • A retry or back-to-home option is provided.
Last updated on