Fix test in HTTPClientMock.test.ts
This commit is contained in:
parent
31bb2aa5ee
commit
61e7e8db4f
@ -30,8 +30,9 @@ describe('HTTPClientMock', () => {
|
|||||||
{method: 'get', url: '/test'},
|
{method: 'get', url: '/test'},
|
||||||
{error: 'Internal'}, 500)
|
{error: 'Internal'}, 500)
|
||||||
|
|
||||||
|
const errorPromise = http.get('/test')
|
||||||
const waitPromise = http.wait()
|
const waitPromise = http.wait()
|
||||||
const error = await getError(http.get('/test'))
|
const error = await getError(errorPromise)
|
||||||
const error2 = await getError(waitPromise)
|
const error2 = await getError(waitPromise)
|
||||||
expect(error.message).toEqual('HTTP Status: 500')
|
expect(error.message).toEqual('HTTP Status: 500')
|
||||||
expect(error2).toBe(error)
|
expect(error2).toBe(error)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user