diff options
Diffstat (limited to 'shared/extra-utils/mock-servers/mock-proxy.ts')
-rw-r--r-- | shared/extra-utils/mock-servers/mock-proxy.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/shared/extra-utils/mock-servers/mock-proxy.ts b/shared/extra-utils/mock-servers/mock-proxy.ts index eb5f177c7..f955d3f9e 100644 --- a/shared/extra-utils/mock-servers/mock-proxy.ts +++ b/shared/extra-utils/mock-servers/mock-proxy.ts | |||
@@ -2,6 +2,7 @@ | |||
2 | import { createServer, Server } from 'http' | 2 | import { createServer, Server } from 'http' |
3 | import proxy from 'proxy' | 3 | import proxy from 'proxy' |
4 | import { randomInt } from '@shared/core-utils' | 4 | import { randomInt } from '@shared/core-utils' |
5 | import { terminateServer } from './utils' | ||
5 | 6 | ||
6 | class MockProxy { | 7 | class MockProxy { |
7 | private server: Server | 8 | private server: Server |
@@ -16,7 +17,7 @@ class MockProxy { | |||
16 | } | 17 | } |
17 | 18 | ||
18 | terminate () { | 19 | terminate () { |
19 | if (this.server) this.server.close() | 20 | return terminateServer(this.server) |
20 | } | 21 | } |
21 | } | 22 | } |
22 | 23 | ||