From f9a6cc3f03ceecba7b00236a91e5eacbe0a6b9d2 Mon Sep 17 00:00:00 2001 From: Mathias Lykkegaard Lorenzen Date: Mon, 2 Dec 2024 16:05:59 +0100 Subject: [PATCH] chore: export variables from node compat tools script (#27189) --- tests/node_compat/runner/setup.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/node_compat/runner/setup.ts b/tests/node_compat/runner/setup.ts index 32c0e2a63aee40..eeae3ae92d1674 100755 --- a/tests/node_compat/runner/setup.ts +++ b/tests/node_compat/runner/setup.ts @@ -19,7 +19,7 @@ const encoder = new TextEncoder(); const NODE_VERSION = version; -const NODE_IGNORED_TEST_DIRS = [ +export const NODE_IGNORED_TEST_DIRS = [ "addons", "async-hooks", "cctest", @@ -40,13 +40,13 @@ const NODE_IGNORED_TEST_DIRS = [ "wpt", ]; -const VENDORED_NODE_TEST = new URL("./suite/test/", import.meta.url); -const NODE_COMPAT_TEST_DEST_URL = new URL( +export const VENDORED_NODE_TEST = new URL("./suite/test/", import.meta.url); +export const NODE_COMPAT_TEST_DEST_URL = new URL( "../test/", import.meta.url, ); -async function getNodeTests(): Promise { +export async function getNodeTests(): Promise { const paths: string[] = []; const rootPath = VENDORED_NODE_TEST.href.slice(7); for await ( @@ -61,7 +61,7 @@ async function getNodeTests(): Promise { return paths.sort(); } -function getDenoTests() { +export function getDenoTests() { return Object.entries(config.tests) .filter(([testDir]) => !NODE_IGNORED_TEST_DIRS.includes(testDir)) .flatMap(([testDir, tests]) => tests.map((test) => testDir + "/" + test));