Skip to content

Commit 99bccdd

Browse files
Achanandhi-MAchanandhi
andauthored
chore:update flask mongo quickstart (#508)
Signed-off-by: Achanandhi <[email protected]> Co-authored-by: Achanandhi <[email protected]>
1 parent 15a1356 commit 99bccdd

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

versioned_docs/version-2.0.0/quickstart/python-flask-mongo.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,25 +69,25 @@ To generate testcases we just need to **make some API calls.**
6969
1. **Make a POST request:**
7070

7171
```bash
72-
curl -X POST -H "Content-Type: application/json" -d '{"title":"Task 1","description":"Important task"}' http://localhost:5000/api/tasks
72+
curl -X POST -H "Content-Type: application/json" -d '{"student_id": "12345", "name": "John Doe", "age": 20}' http://localhost:6000/students
7373
```
7474

7575
2. **Make a GET request:**
7676

7777
```bash
78-
curl http://localhost:5000/api/tasks
78+
curl http://localhost:6000/students
7979
```
8080

8181
3. **Make a PUT request:**
8282

8383
```bash
84-
curl -X PUT -H "Content-Type: application/json" -d '{"title":"Task 1","description":"Random task"}' http://localhost:5000/api/tasks/12345
84+
curl -X PUT -H "Content-Type: application/json" -d '{"name": "Jane Smith", "age": 21}' http://localhost:6000/students/12345
8585
```
8686

8787
4. **Make a DELETE request:**
8888

8989
```bash
90-
curl -X DELETE http://localhost:5000/api/tasks/12345
90+
curl -X DELETE http://localhost:6000/students/12345
9191
```
9292

9393
And once you are done, you can stop the recording and give yourself a pat on the back! With that simple spell, you've conjured up a test case with a mock! Explore the **keploy** directory and you'll discover your handiwork in `tests` directory and `mocks.yml`.

0 commit comments

Comments
 (0)