Skip to content

Commit

Permalink
test: update failure messages for clarity
Browse files Browse the repository at this point in the history
  • Loading branch information
orinokai committed Jul 25, 2024
1 parent da8215f commit fb8d9ea
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/integration/edge-handler.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ describe("aborts middleware execution when the matcher conditions don't match th
})
expect(
response.headers.has('x-hello-from-middleware-res'),
`does not match ${path}`,
`should match ${path}`,
).toBeTruthy()
expect(await response.text()).toBe('Hello from origin!')
expect(response.status).toBe(200)
Expand All @@ -281,7 +281,10 @@ describe("aborts middleware execution when the matcher conditions don't match th
origin,
url: path,
})
expect(response.headers.has('x-hello-from-middleware-res'), `does match ${path}`).toBeFalsy()
expect(
response.headers.has('x-hello-from-middleware-res'),
`should not match ${path}`,
).toBeFalsy()
expect(await response.text()).toBe('Hello from origin!')
expect(response.status).toBe(200)
}
Expand Down

0 comments on commit fb8d9ea

Please sign in to comment.