From 2d7173a9f29a87fe5fe77c15b08faf45a621416b Mon Sep 17 00:00:00 2001 From: Frazer Smith Date: Sun, 10 Sep 2023 08:31:35 +0100 Subject: [PATCH] perf: use `node:` prefix to bypass require.cache call for builtins See https://github.com/fastify/fastify-static/pull/407 --- test.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test.js b/test.js index 7cd5761..a974f07 100644 --- a/test.js +++ b/test.js @@ -1,10 +1,10 @@ 'use strict' const { test } = require('tap') -const { join, basename } = require('path') -const { mkdtempSync, readdirSync } = require('fs') -const { tmpdir } = require('os') -const { spawnSync } = require('child_process') +const { join, basename } = require('node:path') +const { mkdtempSync, readdirSync } = require('node:fs') +const { tmpdir } = require('node:os') +const { spawnSync } = require('node:child_process') test('generates a fastify project in the current folder', async ({ equal, match }) => { const dir = mkdtempSync(join(tmpdir(), 'create-fastify-test'))