aboutsummaryrefslogtreecommitdiff
path: root/packages/integrations/vercel/test/speed-insights.test.js
diff options
context:
space:
mode:
authorGravatar Ming-jun Lu <40516784+mingjunlu@users.noreply.github.com> 2024-02-13 21:23:07 +0800
committerGravatar GitHub <noreply@github.com> 2024-02-13 13:23:07 +0000
commit37c75108e7b4b0c8feacadc0a1e49f58ebf8905d (patch)
tree7092c1bc786cd2267c23aa606b8897c9fae468a4 /packages/integrations/vercel/test/speed-insights.test.js
parenta326124f5a1267361b3d36af24bf042b2f1ac41f (diff)
downloadastro-37c75108e7b4b0c8feacadc0a1e49f58ebf8905d.tar.gz
astro-37c75108e7b4b0c8feacadc0a1e49f58ebf8905d.tar.zst
astro-37c75108e7b4b0c8feacadc0a1e49f58ebf8905d.zip
chore(@astrojs/vercel): migrate tests to `node:test` (#10010)
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
Diffstat (limited to 'packages/integrations/vercel/test/speed-insights.test.js')
-rw-r--r--packages/integrations/vercel/test/speed-insights.test.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/packages/integrations/vercel/test/speed-insights.test.js b/packages/integrations/vercel/test/speed-insights.test.js
index 7cf2ae778..4da6597e1 100644
--- a/packages/integrations/vercel/test/speed-insights.test.js
+++ b/packages/integrations/vercel/test/speed-insights.test.js
@@ -1,5 +1,6 @@
import { loadFixture } from './test-utils.js';
-import { expect } from 'chai';
+import assert from 'node:assert/strict';
+import { before, describe, it } from 'node:test';
describe('Vercel Speed Insights', () => {
describe('output: server', () => {
@@ -19,7 +20,7 @@ describe('Vercel Speed Insights', () => {
const bundle = await fixture.readFile(`../.vercel/output/static/_astro/${page}`);
- expect(bundle).to.contain('https://vitals.vercel-analytics.com/v1/vitals');
+ assert.match(bundle, /https:\/\/vitals.vercel-analytics.com\/v1\/vitals/)
});
});
@@ -40,7 +41,7 @@ describe('Vercel Speed Insights', () => {
const bundle = await fixture.readFile(`../.vercel/output/static/_astro/${page}`);
- expect(bundle).to.contain('https://vitals.vercel-analytics.com/v1/vitals');
+ assert.match(bundle, /https:\/\/vitals.vercel-analytics.com\/v1\/vitals/);
});
});
});