Skip to content

Commit

Permalink
fix(waitForPort): wait for delay
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 committed Feb 25, 2022
1 parent 130b1fd commit 01497a8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ export async function waitForPort (port: PortNumber, opts: WaitForPortOptions =
if (await _checkPort(port, opts.host) === false) {
return
}
await new Promise(resolve => setTimeout(resolve, delay))
}
throw new Error(`Timeout waiting for port ${port} after ${retries} retries with ${delay}ms interval.`)
}
Expand Down

0 comments on commit 01497a8

Please sign in to comment.