fix(tool-web): bound HTML conversion work
This commit is contained in:
@@ -45,8 +45,11 @@ export async function apply(ctx) {
|
||||
})
|
||||
// The fixture must never hold the process open past protocol shutdown.
|
||||
server.unref()
|
||||
ctx.effect(() => () => {
|
||||
server.close()
|
||||
server.closeAllConnections()
|
||||
ctx.effect(() => async () => {
|
||||
await new Promise((resolve, reject) => {
|
||||
server.close(error => error ? reject(error) : resolve(undefined))
|
||||
// Stop accepting first so a connection cannot arrive after the forced close.
|
||||
server.closeAllConnections()
|
||||
})
|
||||
}, 'web-fetch-fixture-server')
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user