Explorar el Código

fix(testing): More graceful shutdown

Michael Bromley hace 2 años
padre
commit
aa91bd0610
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      packages/testing/src/test-server.ts

+ 1 - 1
packages/testing/src/test-server.ts

@@ -61,7 +61,7 @@ export class TestServer {
     async destroy() {
         // allow a grace period of any outstanding async tasks to complete
         await new Promise(resolve => global.setTimeout(resolve, 500));
-        await this.app.close();
+        await this.app?.close();
     }
 
     private getCallerFilename(depth: number): string {