Files
gitjet.ru/.docs/branches/main/448c71f5/testing.md
T

4.2 KiB

Test strategy

The test strategy for the GitJet application will involve a combination of unit testing, integration testing, and end-to-end (e2e) testing. The goal is to ensure that all components of the application work together correctly and produce expected results.

Test tactics

  1. Unit Testing: This involves testing individual functions or methods in isolation to verify their correctness.
  2. Integration Testing: this involves testing the interactions between different components to ensure they are working together as intended.
  3. End-to-end Testing: this involves testing the entire application from start to finish to ensure that all features work together seamlessly.

Test cases (mapped to use cases)

UC-ID Test Level (unit/integration/e2e) Preconditions Steps Expected
UC1 Search repositories with keyword "python" e2e None 1. Open the application
2. Click on the search bar
3. Enter "python" in the search bar
4. Press enter
5. Verify that the results display repositories related to Python
All repositories related to Python should be displayed
UC1 Search repositories with keyword "flask" e2e None 1. Open the application
2. Click on the search bar
3. Enter "flask" in the search bar
4. Press enter
5. Verify that the results display repositories related to Flask
All repositories related to Flask should be displayed
UC1 Search repositories with keyword "git" e2e None 1. Open the application
2. Click on the search bar
3. Enter "git" in the search bar
4. Press enter
5. Verify that the results display repositories related to Git
All repositories related to Git should be displayed
UC2 View repository details for a specific repository e2e None 1. Open the application
2. Click on the search bar
3. Enter "python" in the search bar
4. Press enter
5. Click on a repository from the search results
6. Verify that the details of the selected repository are displayed
The details of the selected repository should be displayed
UC2 View repository details for another specific repository e2e None 1. Open the application
2. Click on the search bar
3. Enter "flask" in the search bar
4. Press enter
5. Click on a repository from the search results
6. Verify that the details of the selected repository are displayed
The details of the selected repository should be displayed
UC2 View repository details for yet another specific repository e2e None 1. Open the application
2. Click on the search bar
3. Enter "git" in the search bar
4. Press enter
5. Click on a repository from the search results
6. Verify that the details of the selected repository are displayed
The details of the selected repository should be displayed
UC3 View user profile for the logged-in user e2e None 1. Open the application
2. Log in as a user
3. Click on the user's profile icon
4. Verify that their profile information is displayed
The profile information of the logged-in user should be displayed
UC3 View user profile for another user e2e None 1. Open the application
2. Log in as a user
3. Click on the search bar
4. Enter the username of another user
5. Click on the result
6. Verify that the profile information of the selected user is displayed
The profile information of the selected user should be displayed

Smoke

  • Test UC1 with a keyword "python" to ensure search functionality works correctly.
  • Test UC2 with a repository ID to ensure viewing repository details works correctly.
  • Test UC3 with a username to ensure viewing user profiles works correctly.

Regression

  • Test all use cases after making changes to the application code or configuration to ensure that existing features continue to work as expected.

Edge cases

  • Test UC1 with an empty search bar to ensure no results are displayed when searching for nothing.
  • Test UC2 with a repository ID that does not exist in the database to ensure appropriate error handling is implemented.
  • Test UC3 with a username that does not exist in the database to ensure appropriate error handling is implemented.