node/test/fixtures/es-module-loaders/loader-unknown-builtin-module.mjs
Jacob Smith 447635b440
test: refactor ESM tests to improve performance
PR-URL: https://github.com/nodejs/node/pull/43784
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2022-07-29 10:42:55 +02:00

8 lines
180 B
JavaScript

export function resolve(specifier, context, next) {
if (specifier === 'unknown-builtin-module') return {
url: 'node:unknown-builtin-module'
};
return next(specifier);
}