node/test/es-module
Geoffrey Booth 2d49e0e635 esm: rewrite loader hooks test
Rewrite the test that validates that custom loader hooks are called from
being a test that depends on internals to one that spawns a child
process and checks its output to confirm expected behavior.

PR-URL: https://github.com/nodejs/node/pull/46016
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Jacob Smith <jacob@frende.me>
2023-01-05 13:11:42 -03:00
..
es-module.status
test-cjs-esm-warn.js test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-cjs-prototype-pollution.js esm: protect ESM loader from prototype pollution 2022-11-10 09:42:59 -03:00
test-esm-assert-strict.mjs
test-esm-assertionless-json-import.js module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-basic-imports.mjs esm: improve typings and code coverage 2022-03-14 16:30:26 +01:00
test-esm-child-process-fork-main.mjs child_process: queue pending messages 2021-12-30 05:59:49 -08:00
test-esm-cjs-builtins.js test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-cjs-exports.js src,test: fix typos 2022-08-03 23:48:09 +02:00
test-esm-cjs-load-error-note.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-cjs-main.js test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-cjs-named-error.mjs
test-esm-custom-exports.mjs
test-esm-cyclic-dynamic-import.mjs
test-esm-data-urls.js test: adapt to new JSON SyntaxError messages 2022-10-11 07:27:56 +02:00
test-esm-default-type.mjs
test-esm-dns-promises.mjs
test-esm-double-encoding.mjs
test-esm-dynamic-import-assertion.js module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-dynamic-import-assertion.mjs module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-dynamic-import.js errors: refactor to use a method that formats a list string 2023-01-05 13:11:36 -03:00
test-esm-encoded-path-native.js test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-encoded-path.mjs lib: fix regular expression to detect / and \ 2021-10-21 14:55:00 +00:00
test-esm-error-cache.js
test-esm-example-loader.mjs esm: consolidate ESM loader hooks 2021-09-11 18:08:35 -07:00
test-esm-experimental-warnings.mjs esm: remove specifier resolution flag 2022-10-04 09:44:08 +00:00
test-esm-export-not-found.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-exports-deprecations.mjs module: exports & imports map invalid slash deprecation 2022-09-11 12:01:37 +02:00
test-esm-exports.mjs module: exports & imports map invalid slash deprecation 2022-09-11 12:01:37 +02:00
test-esm-forbidden-globals.mjs
test-esm-fs-promises.mjs
test-esm-import-assertion-1.mjs module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-import-assertion-2.mjs module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-import-assertion-3.mjs module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-import-assertion-4.mjs module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-import-assertion-errors.js esm: support https remotely and http locally under flag 2022-02-09 19:47:12 -08:00
test-esm-import-assertion-errors.mjs esm: support https remotely and http locally under flag 2022-02-09 19:47:12 -08:00
test-esm-import-assertion-validation.js module: import assertions improvements 2021-11-24 15:50:05 +00:00
test-esm-import-flag.mjs esm: add --import flag 2022-07-31 04:08:02 +01:00
test-esm-import-json-named-export.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-import-meta-resolve.mjs Revert "esm: convert resolve hook to synchronous" 2022-06-22 08:13:36 +01:00
test-esm-import-meta.mjs
test-esm-imports-deprecations.mjs module: fix segment deprecation for imports field 2022-10-13 07:31:31 -07:00
test-esm-imports.mjs module: fix segment deprecation for imports field 2022-10-13 07:31:31 -07:00
test-esm-initialization.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-invalid-data-urls.js esm: support https remotely and http locally under flag 2022-02-09 19:47:12 -08:00
test-esm-invalid-pjson.js test: adapt to new JSON SyntaxError messages 2022-10-11 07:27:56 +02:00
test-esm-json-cache.mjs module: unflag esm json modules 2022-01-31 22:16:37 +00:00
test-esm-json.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-live-binding.mjs
test-esm-loader-cache-clearing.js
test-esm-loader-chaining.mjs esm: fix loader hooks accepting too many arguments 2022-08-04 22:10:13 +00:00
test-esm-loader-custom-condition.mjs
test-esm-loader-dependency.mjs
test-esm-loader-hooks.mjs esm: rewrite loader hooks test 2023-01-05 13:11:42 -03:00
test-esm-loader-http-imports.mjs esm: add --import flag 2022-07-31 04:08:02 +01:00
test-esm-loader-invalid-format.mjs
test-esm-loader-invalid-url.mjs esm: add chaining to loaders 2022-05-04 16:51:12 +01:00
test-esm-loader-mock.mjs esm: working mock test 2021-11-29 14:54:01 -06:00
test-esm-loader-modulemap.js module: import assertions improvements 2021-11-24 15:50:05 +00:00
test-esm-loader-not-found.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-loader-obsolete-hooks.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-loader-resolve-type.mjs test: fix comments in test files 2022-03-31 08:48:03 +02:00
test-esm-loader-search.js Revert "esm: convert resolve hook to synchronous" 2022-06-22 08:13:36 +01:00
test-esm-loader-side-effect.mjs
test-esm-loader-stringify-text.mjs esm: consolidate ESM loader hooks 2021-09-11 18:08:35 -07:00
test-esm-loader-thenable.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-loader-with-syntax-error.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-loader.mjs esm: consolidate ESM loader hooks 2021-09-11 18:08:35 -07:00
test-esm-main-lookup.mjs
test-esm-module-not-found-commonjs-hint.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-named-exports.mjs
test-esm-namespace.mjs
test-esm-no-addons.mjs src: add option to disable loading native addons 2021-09-10 10:54:39 -05:00
test-esm-non-js.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-nowarn-exports.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-path-posix.mjs
test-esm-path-win32.mjs
test-esm-pkgname.mjs lib: fix regular expression to detect / and \ 2021-10-21 14:55:00 +00:00
test-esm-preserve-symlinks-main.js test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-preserve-symlinks-not-found-plain.mjs
test-esm-preserve-symlinks-not-found.mjs
test-esm-preserve-symlinks.js
test-esm-process.mjs process: fix named report export 2022-02-23 18:37:55 +02:00
test-esm-prototype-pollution.mjs esm: protect ESM loader from prototype pollution 2022-11-10 09:42:59 -03:00
test-esm-repl-imports.js test_runner: avoid swallowing of asynchronously thrown errors 2022-11-10 09:45:36 -03:00
test-esm-repl.js
test-esm-require-cache.mjs
test-esm-resolve-type.mjs test: refactor test/es-module/test-esm-resolve-type 2022-07-20 23:40:04 +02:00
test-esm-scope-node-modules.mjs
test-esm-shared-loader-dep.mjs
test-esm-shebang.mjs
test-esm-snapshot.mjs
test-esm-symlink-main.js
test-esm-symlink-type.js
test-esm-symlink.js
test-esm-syntax-error.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-throw-undefined.mjs
test-esm-tla-unfinished.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-tla.mjs
test-esm-type-flag-errors.js
test-esm-type-flag.mjs
test-esm-type-main.mjs
test-esm-undefined-cjs-global-like-variables.js
test-esm-unknown-or-no-extension.js test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-util-types.mjs
test-esm-wasm.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-esm-windows.js
test-http-imports-cli.mjs test: refactor ESM tests to improve performance 2022-07-29 10:42:55 +02:00
test-http-imports.mjs dns: accept 'IPv4' and 'IPv6' for family 2022-06-15 18:02:01 -04:00
testcfg.py