Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
henrybatt committed May 30, 2024
1 parent 9b3bd8c commit 2a127b5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions application/app/tests/test_shareride.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,8 @@ def test_3_conflicting_trip_schedule(self):
def test_4_nondrivers_cannot_create_trip(self):
# Test to check the system properly handles trip creation attempts by non-drivers.
response = self.client.post('/trip/create', json=TRIP_REQUEST_LEO)
self.assertEqual(response.status_code, 301, "Expected status code to be 404 Created")
self.assertEqual(response.json['message'], "Invalid Driver! Please ensure the username is linked to a driver account.",
"Response message should indicate that the user is already a passenger")
self.assertEqual(response.status_code, 301, "Expected status code to be 301 Created")
self.assertEqual(response.json['error'], "That user does not exist or has incorrect login details.")

def test_5_get_all_trips_for_user(self):
# Test to verify that all trips associated with a specific driver can be retrieved.
Expand Down

0 comments on commit 2a127b5

Please sign in to comment.