summaryrefslogtreecommitdiff
path: root/packages/integrations/cloudflare/test/runtime.test.js
diff options
context:
space:
mode:
Diffstat (limited to 'packages/integrations/cloudflare/test/runtime.test.js')
-rw-r--r--packages/integrations/cloudflare/test/runtime.test.js16
1 files changed, 9 insertions, 7 deletions
diff --git a/packages/integrations/cloudflare/test/runtime.test.js b/packages/integrations/cloudflare/test/runtime.test.js
index 8bb38d7e5..e0d77d5c6 100644
--- a/packages/integrations/cloudflare/test/runtime.test.js
+++ b/packages/integrations/cloudflare/test/runtime.test.js
@@ -17,20 +17,22 @@ describe('Runtime Locals', () => {
});
await fixture.build();
- cli = await runCLI('./fixtures/runtime/', { silent: true, port: 8793 });
- await cli.ready.catch((e) => {
- console.log(e);
- // if fail to start, skip for now as it's very flaky
- this.skip();
+ cli = await runCLI('./fixtures/runtime/', {
+ silent: true,
+ onTimeout: (ex) => {
+ console.log(ex);
+ // if fail to start, skip for now as it's very flaky
+ this.skip();
+ },
});
});
after(async () => {
- await cli.stop();
+ await cli?.stop();
});
it('has CF and Caches', async () => {
- let res = await fetch(`http://127.0.0.1:8793/`);
+ let res = await fetch(`http://127.0.0.1:${cli.port}/`);
expect(res.status).to.equal(200);
let html = await res.text();
let $ = cheerio.load(html);