We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent abb80aa commit bdea9c9Copy full SHA for bdea9c9
tests/api/pet-v2.spec.ts
@@ -46,16 +46,18 @@ test(`CRUD - Pet`, ({ request }) => {
46
47
// UPDATE pet status
48
test.step(`PUT - doggie`, async () => {
49
+ const updatedResponse = { ...expectedResponse, status: "sold" };
50
+
51
const response = await request.put(`/v2/pet`, {
52
headers: {
53
"Content-Type": "application/json",
54
accept: "application/json",
55
},
- data: JSON.stringify({ ...expectedResponse, status: "sold" }),
56
+ data: JSON.stringify(updatedResponse),
57
});
58
59
expect(await response.json()).toEqual(
- expect.objectContaining({ ...expectedResponse, status: "sold" })
60
+ expect.objectContaining(updatedResponse)
61
);
62
63
0 commit comments