From 4c2380af5c8561fc0a5f8279c1c7336680d026ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Thu, 16 Feb 2023 14:30:14 +0100 Subject: test: add unit tests from std/node (#17794) Adds two test files: "cli/tests/unit_node/process_test.ts" and "cli/tests/unit_node/child_process_test.ts" --------- Co-authored-by: Yoshiya Hinosawa --- cli/tests/unit_node/testdata/node_modules/foo/index.js | 4 ++++ cli/tests/unit_node/testdata/node_modules/foo/package.json | 3 +++ 2 files changed, 7 insertions(+) create mode 100644 cli/tests/unit_node/testdata/node_modules/foo/index.js create mode 100644 cli/tests/unit_node/testdata/node_modules/foo/package.json (limited to 'cli/tests/unit_node/testdata/node_modules/foo') diff --git a/cli/tests/unit_node/testdata/node_modules/foo/index.js b/cli/tests/unit_node/testdata/node_modules/foo/index.js new file mode 100644 index 000000000..24faba789 --- /dev/null +++ b/cli/tests/unit_node/testdata/node_modules/foo/index.js @@ -0,0 +1,4 @@ +console.log("foo"); +console.log(typeof require === "function"); +console.log(typeof module === "object"); +console.log(typeof exports === "object"); diff --git a/cli/tests/unit_node/testdata/node_modules/foo/package.json b/cli/tests/unit_node/testdata/node_modules/foo/package.json new file mode 100644 index 000000000..bde99de92 --- /dev/null +++ b/cli/tests/unit_node/testdata/node_modules/foo/package.json @@ -0,0 +1,3 @@ +{ + "name": "foo" +} -- cgit v1.2.3