Add put for updating a task.
This commit is contained in:
parent
e2284c7421
commit
026a8be707
3 changed files with 47 additions and 12 deletions
|
|
@ -89,13 +89,13 @@ jsonpath "$.completed_at" exists
|
|||
PUT {{host}}/api/tasks/{{task_id}}
|
||||
Content-Type: application/json
|
||||
{
|
||||
"description": null
|
||||
"description": ""
|
||||
}
|
||||
|
||||
HTTP 200
|
||||
[Asserts]
|
||||
jsonpath "$.id" == "{{task_id}}"
|
||||
jsonpath "$.description" == null
|
||||
jsonpath "$.description" == ""
|
||||
|
||||
# Setup: Create another task for error tests
|
||||
POST {{host}}/api/tasks
|
||||
|
|
@ -152,11 +152,3 @@ HTTP 422
|
|||
[Asserts]
|
||||
jsonpath "$.error" exists
|
||||
|
||||
# Test: Update with no fields (empty object)
|
||||
PUT {{host}}/api/tasks/{{error_test_task_id}}
|
||||
Content-Type: application/json
|
||||
{}
|
||||
|
||||
HTTP 422
|
||||
[Asserts]
|
||||
jsonpath "$.error" exists
|
||||
Loading…
Add table
Add a link
Reference in a new issue