Update checked-in dependencies
This commit is contained in:
parent
c9f0d30a86
commit
95d52b7807
647 changed files with 498055 additions and 3880 deletions
8
node_modules/@mswjs/interceptors/src/RequestController.test.ts
generated
vendored
8
node_modules/@mswjs/interceptors/src/RequestController.test.ts
generated
vendored
|
|
@ -26,6 +26,14 @@ it('resolves the response promise with the error provided to "errorWith"', async
|
|||
await expect(controller[kResponsePromise]).resolves.toEqual(error)
|
||||
})
|
||||
|
||||
it('resolves the response promise with an arbitrary object provided to "errorWith"', async () => {
|
||||
const controller = new RequestController(new Request('http://localhost'))
|
||||
const error = { message: 'Oops!' }
|
||||
controller.errorWith(error)
|
||||
|
||||
await expect(controller[kResponsePromise]).resolves.toEqual(error)
|
||||
})
|
||||
|
||||
it('throws when calling "respondWith" multiple times', () => {
|
||||
const controller = new RequestController(new Request('http://localhost'))
|
||||
controller.respondWith(new Response('hello world'))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue