Testcases and Outcomes - CodingKen02/Group-10 GitHub Wiki

Feature: Database (Req 1)

  1. Test case: Shoe Database Functionality
  • Preconditions: The shoe database should exist.
  • Input: The user will add a new shoe with tags, name, price, and description.
  • Expected output: Verify that the new shoe has been successfully added to the shoe database and that it can be retrieved with all its information.
  • Outcome: Shoe is verified when added successfully to the database.
  1. Test case: User Database Functionality
  • Preconditions: The user database should exist.
  • Input: This user will add a new user with userID, name, email, and password.
  • Expected output: Verify that the new user has been successfully added to the user database and that it can be retrieved with all its information.
  • Outcome: User is verified when added successfully to the database.
  1. Test case: Financial Database Functionality
  • Preconditions: The financial database should exist. The user should have a valid payment method associated with their account.
  • Input: The user will complete a transaction by buying a shoe and making a payment.
  • Expected output: Verify that the financial information of the transaction has been successfully added to the financial database, and that the payment has been received and distributed correctly.
  • Outcome: Transaction is verified when successfully added to the database.
  1. Test case: User Logs in Database
  • Preconditions: The shoe database should exist, and it should have at least one shoe already added.
  • Input: The user will log in with their registered credentials.
  • Expected output: Verify that the user is logged in when redirect to home page.
  • Outcome: The logged in user is redirected to home page.
  1. Test case: User Logs Out of Database.
  • Preconditions: The user database should exist, and it should have at least one user already added.
  • Input: The user will press the logout button.
  • Expected output: Verify that the user has logged out and redirected to the home page.
  • Outcome: The logged-out user is redirect to the home page and out of stored account.

Feature: Search (Req 2)

  1. Test case: Search by keyword
  • Preconditions: The shoe database should exist, and it should have at least one shoe already added.
  • Input: User enters "Nike" in the search bar.
  • Expected output: The search results display all shoes that have "Nike" as their brand name.
  • Outcome: Only Nike shoes appear.
  1. Test case: Search by character(s)
  • Preconditions: The shoe database should exist, and it should have at least one shoe already added.
  • Input: User enters "ad" in the search bar.
  • Expected output: The search results display all shoes that have "ad" in their brand name.
  • Outcome: Only shoes appear with "ad" in the brand name.
  1. Test case: Search non-existing shoe brand
  • Preconditions: The shoe database should exist, and it should have at least one shoe already added.
  • Input: User enters "Gigabyte" in the search bar.
  • Expected output: The search results display message "No matching items found."
  • Outcome: Message appears.
  1. Test case: Search shoe type in search bar
  • Preconditions: The shoe database should exist, and it should have at least one shoe already added.
  • Input: User enters "Jordans" in the search bar.
  • Expected output: The search results display message "No matching items found."
  • Outcome: Message appears.
  1. Test case: Press search button for all shoes
  • Preconditions: The shoe database should exist, and it should have at least one shoe already added.
  • Input: User presses the search button.
  • Expected output: The search results display all shoes.
  • Outcome: All shoes appear.

Feature: Login/Registration (Req 3)

  1. Test Case: Successful Registration
  • Preconditions: The user database should exist.
  • Input: The user will enter a valid (username), password, and email address. Click on the registration button.
  • Expected output: Verify that the user is redirected to the (login) page and their account is created in the database.
  • Outcome: User is redirected to the login page
  1. Test Case: Incorrect Email (Registration/Login)
  • Preconditions: The user database should exist, and may have correct email address stored if registered already.
  • Input: The user will enter an invalid email address (e.g. missing '@' symbol, no domain name, etc.).
  • Expected output: Verify that the user is notified with an error message stating that the email address is invalid and they should enter a valid one.
  • Outcome: User is notified with an error message labeling the email address entered is invalid
  1. Test Case: Incorrect and Case Sensitive Password (Login)
  • Preconditions: The user should have a valid account in the user database.
  • Input: The user will enter an invalid password.
  • Expected output: Verify that the user is notified with an error message stating that the password is invalid and they should enter the valid one.
  • Outcome: User is properly notified
  1. Test Case: Reverse Login
  • Preconditions: The user database should exist.
  • Input: The user will enter their password in the email field and the email address in the password field.
  • Expected output: Verify that the user is redirected to the login as those data attempts are not correct. Also notified that the email field needs an @ symbol.
  • Outcome: User is properly redirected and notified.
  1. Test Case: Successful Login
  • Preconditions: The user should have a valid account in the user database.
  • Input: The user will enter a valid (username), password, and email address. Click on the login button.
  • Expected output: Verify that the user is redirected to the (home) page and logged in.
  • Outcome: User is logged in, and the website reflects this with the greeting message located at the top right.

Feature: User Account Page (Req 4)

  1. Test Case: User View Information
  • Preconditions: The user should have a valid account in the user database.
  • Input: Navigate to user account page.
  • Expected output: The user should be able to view their cart items, order history, account details, and preferences.
  • Outcome: User is able to access their account page
  1. Test Case: Delete Account
  • Preconditions: User is logged in and has a user account.
  • Inputs: Navigate to the "Account Settings" page. Click on the "Delete Account" button. Verify that a confirmation message appears asking the user to confirm that they want to delete their account. Enter valid password. Click on the "Confirm" button to delete the account. Verify that the user is logged out and redirected to the home page.
  • Expected Result: User's account should be deleted and they should be logged out of the website.
  • Outcome: User's account is deleted and they are sent back to the home page.
  1. Test Case: Update User Account
  • Preconditions: The user should have a valid account in the user database.
  • Input: Click on the "edit account details" button and make changes to the user's name, email address, or password.
  • Expected output: The user's account details should be updated in the database and reflected on their account page.
  • Outcome: User's details are properly updated.
  1. Test Case: Add Items to Cart
  • Preconditions: The shoe database should exist. The user should have a valid account in the user database.
  • Input: Click on the "add to cart" button for an item and navigate to the user's cart page.
  • Expected output: The item should be added to the user's cart and reflected on their cart page.
  • Outcome: User's cart page is updated.
  1. Test Case: View Order History
  • Preconditions: The user should have a valid account in the user database, and they should have at least one order in their order history.
  • Input: Navigate to user account page and click on the "order history" button.
  • Expected output: The user should be able to view a list of their previous orders and click on an order to view its details, such as order date, items purchased, and order total.
  • Outcome: User can view their order history.