Skip to content

Commit a1d37ae

Browse files
committed
Go
1 parent e0da615 commit a1d37ae

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

integration-tests/tests/apollo-router/apollo-router.test.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,17 @@ describe('Apollo Router Integration', () => {
5858
},
5959
});
6060
await new Promise((resolve, reject) => {
61-
if (!routerProc.all) {
61+
routerProc.catch(err => {
62+
if (!err.isCanceled) {
63+
reject(err);
64+
}
65+
});
66+
const routerProcOut = routerProc.all;
67+
if (!routerProcOut) {
6268
return reject(new Error('No stdout from Apollo Router process'));
6369
}
6470
let log = '';
65-
routerProc.all.on('data', data => {
71+
routerProcOut.on('data', data => {
6672
log += data.toString();
6773
if (log.includes('GraphQL endpoint exposed at')) {
6874
resolve(true);

0 commit comments

Comments
 (0)