Skip to content

Test Results (Jose Espinoza) #12

@joseespinoza15432

Description

@joseespinoza15432

Workflow 1: Billy Assigns Extra Chores to Himself

STEP 1
curl -X 'GET'
'https://chore-tracker-api.onrender.com/chores/get_chore'
-H 'accept: application/json'
-H 'access_token: a'

REQUEST URL
https://chore-tracker-api.onrender.com/chores/get_chore

RESPONSE

[
{
"name": "mop floors",
"location_in_house": "All rooms",
"frequency": "weekly",
"duration": 25,
"priority": 5,
"due_date": "2024-10-27"
},
{
"name": "wash dishes",
"location_in_house": "kitchen",
"frequency": "daily",
"duration": 20,
"priority": 5,
"due_date": "2024-10-27"
},
{
"name": "take out trash",
"location_in_house": "kitchen",
"frequency": "daily",
"duration": 5,
"priority": 1,
"due_date": "2024-11-07"
},
{
"name": "clean your room",
"location_in_house": "bedroom",
"frequency": "weekly",
"duration": 30,
"priority": 1,
"due_date": "2024-11-05"
},
{
"name": "clean your room",
"location_in_house": "bedroom",
"frequency": "weekly",
"duration": 30,
"priority": 1,
"due_date": "2024-11-05"
},
{
"name": "clean your room",
"location_in_house": "bedroom",
"frequency": "weekly",
"duration": 30,
"priority": 1,
"due_date": "2024-11-05"
},
{
"name": "mop your room",
"location_in_house": "bedroom",
"frequency": "weekly",
"duration": 30,
"priority": 1,
"due_date": "2024-11-05"
},
{
"name": "Clean the bathroom",
"location_in_house": "bathroom",
"frequency": "weekly",
"duration": 20,
"priority": 5,
"due_date": "2024-11-09"
},
{
"name": "test",
"location_in_house": "test",
"frequency": "daily",
"duration": 20,
"priority": 1,
"due_date": "2024-11-06"
},
{
"name": "clean fridge",
"location_in_house": "kitchen",
"frequency": "monthly",
"duration": 60,
"priority": 4,
"due_date": "2024-11-06"
},
{
"name": "APItesting",
"location_in_house": "string",
"frequency": "daily",
"duration": 10,
"priority": 3,
"due_date": "2024-11-09"
},
{
"name": "Mop the floors",
"location_in_house": "kitchen",
"frequency": "daily",
"duration": 30,
"priority": 1,
"due_date": "2024-11-10"
},
{
"name": "Deep clean kitchen",
"location_in_house": "kitchen",
"frequency": "weekly",
"duration": 45,
"priority": 5,
"due_date": "2024-11-16"
},
{
"name": "Deep clean kitchen",
"location_in_house": "kitchen",
"frequency": "weekly",
"duration": 45,
"priority": 1,
"due_date": "2024-11-16"
},
{
"name": "string",
"location_in_house": "string",
"frequency": "daily",
"duration": 0,
"priority": 1,
"due_date": "2023-11-11"
},
{
"name": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
"location_in_house": "string",
"frequency": "daily",
"duration": 0,
"priority": 1,
"due_date": "2023-11-11"
},
{
"name": "string",
"location_in_house": "string",
"frequency": "daily",
"duration": 0,
"priority": 1,
"due_date": "2024-11-11"
},
{
"name": "string",
"location_in_house": "string",
"frequency": "daily",
"duration": 0,
"priority": 2,
"due_date": "2024-11-11"
},
{
"name": "WATCH ARCANE(solid tv show)",
"location_in_house": "Living Room",
"frequency": "daily",
"duration": 540,
"priority": 2,
"due_date": "2024-11-11"
},
{
"name": "WATCH ARCANE(solid tv show)",
"location_in_house": "True",
"frequency": "daily",
"duration": 540,
"priority": 2,
"due_date": "2024-11-11"
},
{
"name": "12",
"location_in_house": "True",
"frequency": "daily",
"duration": 540,
"priority": 2,
"due_date": "2024-11-11"
},
{
"name": "12",
"location_in_house": "True",
"frequency": "daily",
"duration": 540,
"priority": 2,
"due_date": "2024-11-11"
},
{
"name": "Clean",
"location_in_house": "Bedroom",
"frequency": "daily",
"duration": 60,
"priority": 5,
"due_date": "2024-11-11"
},
{
"name": "Clean",
"location_in_house": "Gym",
"frequency": "daily",
"duration": 5,
"priority": 3,
"due_date": "2024-11-12"
},
{
"name": "Clean",
"location_in_house": "Bathroom",
"frequency": "daily",
"duration": 15,
"priority": 5,
"due_date": "2024-11-12"
}
]

STEP 2

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/assign_chore/?chore_id=2&roommate_id=3'
-H 'accept: application/json'
-H 'access_token: a'
-d ''

Request URL
https://chore-tracker-api.onrender.com/chores/assign_chore/?chore_id=2&roommate_id=3

RESPONSE

{
"detail": "This chore assignment already exists for the specified roommate."
}

STEP 3

curl -X 'PATCH'
'https://chore-tracker-api.onrender.com/chores/2/assignments/3/status'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"status": "completed"
}'

Request URL
https://chore-tracker-api.onrender.com/chores/2/assignments/3/status

Response body
{
"message": "Chore status updated successfully!",
"chore_id": 2,
"roommate_id": 3,
"new_status": "completed"
}

WORKFLOW 2: Sarah Tracks Roommate Productivity and Adds Lisa

STEP 1

curl -X 'GET'
'https://chore-tracker-api.onrender.com/chores/history'
-H 'accept: application/json'
-H 'access_token: a'

Response body
[
{
"title": "take out trash",
"completed_by": "Lisa Smith",
"completion_date": "2024-11-07"
},
{
"title": "clean fridge",
"completed_by": "Jimmy Doi",
"completion_date": "2024-11-06"
},
{
"title": "mop floors",
"completed_by": "sue sue",
"completion_date": "2024-10-27"
},
{
"title": "mop floors",
"completed_by": "Billy Bob",
"completion_date": "2024-10-27"
},
{
"title": "mop floors",
"completed_by": "sue sue",
"completion_date": "2024-10-27"
},
{
"title": "wash dishes",
"completed_by": "Billy Bob",
"completion_date": "2024-10-27"
},
{
"title": "wash dishes",
"completed_by": "Antony LeGoat",
"completion_date": "2024-10-27"
},
{
"title": "mop floors",
"completed_by": "sue sue",
"completion_date": "2024-10-27"
}
]

STEP 2

curl -X 'POST'
'https://chore-tracker-api.onrender.com/roommates/create_roommate'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"first_name": "lisa",
"last_name": "Smith",
"email": "Lsmith@gmail.com"
}'

Response body
{
"First Name": "lisa",
"Last Name": "Smith",
"Email": "Lsmith@gmail.com",
"roommate id": 18
}

Step 3

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/create_chore'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"name": "clean the bathroom",
"location_in_house": "house",
"frequency": "weekly",
"duration_mins": 20,
"priority": 5,
"due_date": "2024-11-12"
}'

Response body
{
"message": "Chore clean the bathroom created successully.",
"chore_id": 35
}

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/assign_chore/?chore_id=35&roommate_id=18'
-H 'accept: application/json'
-H 'access_token: a'
-d ''

Response body
{
"chore_id": 35,
"roommate_id": 18,
"status": "pending"
}

Workflow 3: Sue Manages Shared Expenses and Creates a Bill

Step 1:

curl -X 'POST'
'https://chore-tracker-api.onrender.com/bills/create_bill'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money"
}'

Response body
{
"bill_id": 21,
"message": "Bill created and assigned to roommates."
}

STEP 2

curl -X 'GET'
'https://chore-tracker-api.onrender.com/bills/7/assignments'
-H 'accept: application/json'
-H 'access_token: a'

{
"bill_id": 7,
"assignments": [
{
"roommate_id": 1,
"status": "unpaid",
"amount": 26
},
{
"roommate_id": 2,
"status": "unpaid",
"amount": 26
},
{
"roommate_id": 3,
"status": "unpaid",
"amount": 26
},
{
"roommate_id": 4,
"status": "unpaid",
"amount": 26
},
{
"roommate_id": 10,
"status": "unpaid",
"amount": 26
}
]
}

STEP 3

curl -X 'GET'
'https://chore-tracker-api.onrender.com/bills/get_bill'
-H 'accept: application/json'
-H 'access_token: a'

[
{
"total_cost": 1000,
"due_date": "2024-12-01",
"bill_type": "rent",
"message": "pay by updated due date",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 1000,
"due_date": "2024-12-01",
"bill_type": "rent",
"message": "pay by updated due date",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 1000,
"due_date": "2024-12-01",
"bill_type": "rent",
"message": "pay by updated due date",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "paid"
},
{
"total_cost": 1000,
"due_date": "2024-12-01",
"bill_type": "rent",
"message": "pay by updated due date",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "paid"
},
{
"total_cost": 300,
"due_date": "2024-11-05",
"bill_type": "internet",
"message": "to pay",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 300,
"due_date": "2024-11-05",
"bill_type": "internet",
"message": "to pay",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 300,
"due_date": "2024-11-05",
"bill_type": "internet",
"message": "to pay",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 300,
"due_date": "2024-11-05",
"bill_type": "internet",
"message": "to pay",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 300,
"due_date": "2024-11-05",
"bill_type": "internet",
"message": "to pay",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 120,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "important!",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 120,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "important!",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 120,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "important!",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 120,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "important!",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 120,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "important!",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 100,
"due_date": "2024-11-06",
"bill_type": "trash",
"message": "settle up by nov 19",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 100,
"due_date": "2024-11-06",
"bill_type": "trash",
"message": "settle up by nov 19",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 100,
"due_date": "2024-11-06",
"bill_type": "trash",
"message": "settle up by nov 19",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 100,
"due_date": "2024-11-06",
"bill_type": "trash",
"message": "settle up by nov 19",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 100,
"due_date": "2024-11-06",
"bill_type": "trash",
"message": "settle up by nov 19",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 130,
"due_date": "2024-11-06",
"bill_type": "groceries",
"message": "pay for oct groceries",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 130,
"due_date": "2024-11-06",
"bill_type": "groceries",
"message": "pay for oct groceries",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 130,
"due_date": "2024-11-06",
"bill_type": "groceries",
"message": "pay for oct groceries",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 130,
"due_date": "2024-11-06",
"bill_type": "groceries",
"message": "pay for oct groceries",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 130,
"due_date": "2024-11-06",
"bill_type": "groceries",
"message": "pay for oct groceries",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 55,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "test",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 55,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "test",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 55,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "test",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 55,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "test",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 13,
"roommate_name": "string string",
"status": "paid"
},
{
"total_cost": 55,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "test",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "paid"
},
{
"total_cost": 55,
"due_date": "2024-12-01",
"bill_type": "electricity",
"message": "test",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "paid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 1413,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "Pay the damn bill",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": -1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": -10.34,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 1,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "paid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-11",
"bill_type": "electricity",
"message": "string",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "",
"roommate_id": 14,
"roommate_name": "string string",
"status": "paid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-12-31",
"bill_type": "electricity",
"message": "string",
"roommate_id": 14,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 14,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 0,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 15,
"roommate_name": "Billy string",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 14,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": -150,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string",
"roommate_id": 15,
"roommate_name": "Billy string",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 14,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 15,
"roommate_name": "Billy string",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 14,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 200,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "Lets pay this early",
"roommate_id": 15,
"roommate_name": "Billy string",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 1,
"roommate_name": "Antony LeGoat",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 2,
"roommate_name": "sue sue",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 3,
"roommate_name": "Billy Bob",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 4,
"roommate_name": "Lisa Olander",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 10,
"roommate_name": "Lisa Smith",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 11,
"roommate_name": "Jimmy Doi",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 12,
"roommate_name": "Jonathan DeBarro",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 13,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 14,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 15,
"roommate_name": "Billy string",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 16,
"roommate_name": "string string",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 17,
"roommate_name": "The Thing",
"status": "unpaid"
},
{
"total_cost": 100000000,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "need money",
"roommate_id": 18,
"roommate_name": "lisa Smith",
"status": "unpaid"
}
]

STEP 4

curl -X 'PATCH'
'https://chore-tracker-api.onrender.com/bills/update_bill_list_status/21/payments/18'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"status": "paid"
}'

{
"message": "Payment status for roommate id 18 on bill id 21 updated to paid."
}

STEP 5

curl -X 'PATCH'
'https://chore-tracker-api.onrender.com/bills/update_bill/21'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"due_date": "2024-12-31",
"bill_type": "gas",
"message": "electricity to gas"
}'

{
"message": "Bill ID: 21 is updated successfully."
}

NEW TEST CASES

  1. Assigning chores past the due date.

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/create_chore'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"name": "clean",
"location_in_house": "casa",
"frequency": "daily",
"duration_mins": 30,
"priority": 2,
"due_date": "2024-11-08"
}'

Response body
{
"message": "Chore clean created successully.",
"chore_id": 37
}

Purpose: system should either throw out a bad request since it is past the due date or flag it as late.

  1. Completing a chore without assigned word

curl -X 'PATCH'
'https://chore-tracker-api.onrender.com/chores/3/assignments/3/status'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"status": "string"
}'

Purpose: Check to see what the system gives out for unspecified words. In this case all i get is a 500 error. I should get a description of available options or words.

  1. Passing in a negative priority value in the chore creation

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/create_chore'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"name": "d",
"location_in_house": "livingroom",
"frequency": "daily",
"duration_mins": 30,
"priority": -2,
"due_date": "2024-11-08"
}'

Error: response status is 500

Response body
Internal Server Error

Description: passing in a negative value in the chore creations causes a 500 error. Potentially adding a restriction on the entries will resolve this issue

  1. Assigning non-existent chores

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/assign_chore/?chore_id=50&roommate_id=100'
-H 'accept: application/json'
-H 'access_token: a'
-d ''

Request URL
https://chore-tracker-api.onrender.com/chores/assign_chore/?chore_id=50&roommate_id=100

Response body
{
"detail": "Roommate not found"
}

Purpose: see how system handles non-existent values. In this case, there is an edge case to protect against both roomates and chores that dont exist.

  1. Creating chores without correct values.

curl -X 'POST'
'https://chore-tracker-api.onrender.com/chores/create_chore'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"name": "clean",
"location_in_house": "livingroom",
"frequency": "",
"duration_mins": 30,
"priority": 2,
"due_date": "2024-11-08"
}'

Response body

Error: response status is 422

{
"message": [
"['body', 'frequency']: value is not a valid enumeration member; permitted: 'daily', 'weekly', 'biweekly', 'monthly', 'bimonthly', 'yearly'"
],
"data": null
}

Description: System correctly identifies missing values and returns a response of valid entries.

  1. Checking chores out of priority section.

curl -X 'GET'
'https://chore-tracker-api.onrender.com/chores/get_chore?priority=12'
-H 'accept: application/json'
-H 'access_token: a'

Response body
[]

Description: System returns blank entry. Maybe try adding exception to this area to return a list of valid priority values.

  1. Creating invalid roomates.

curl -X 'POST'
'https://chore-tracker-api.onrender.com/roommates/create_roommate'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"first_name": "",
"last_name": "",
"email": ""
}'

Response body
{
"First Name": "",
"Last Name": "",
"Email": "",
"roommate id": 20
}

Purpose: System should return invalid entry since a roommate should have at minimum have a name.

  1. Creating a negative value bill

curl -X 'POST'
'https://chore-tracker-api.onrender.com/bills/create_bill'
-H 'accept: application/json'
-H 'access_token: a'
-H 'Content-Type: application/json'
-d '{
"cost": -130,
"due_date": "2024-11-12",
"bill_type": "electricity",
"message": "string"
}'

Purpose: depending on how they want to implement this section in the future they may want to remove the option of having negative bills. Unless there is some sort of overcharge fee that the roommate is trying to give back.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions