Skip to content

Commit

Permalink
esm: fix duplicated test
Browse files Browse the repository at this point in the history
PR-URL: #44779
Reviewed-By: Antoine du Hamel <[email protected]>
Reviewed-By: Michaël Zasso <[email protected]>
  • Loading branch information
GeoffreyBooth authored Sep 28, 2022
1 parent 3d49437 commit 8ec7bfd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 23 deletions.
21 changes: 0 additions & 21 deletions test/es-module/test-esm-specifiers-legacy-flag.mjs

This file was deleted.

7 changes: 5 additions & 2 deletions test/es-module/test-esm-specifiers.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,17 @@ describe('ESM: specifier-resolution=node', { concurrency: true }, () => {
'--eval',
[
'import { strictEqual } from "node:assert";',
// commonJS index.js
// CommonJS index.js
`import commonjs from ${JSON.stringify(fixtures.fileURL('es-module-specifiers/package-type-commonjs'))};`,
// esm index.js
// ESM index.js
`import module from ${JSON.stringify(fixtures.fileURL('es-module-specifiers/package-type-module'))};`,
// Directory entry with main.js
`import main from ${JSON.stringify(fixtures.fileURL('es-module-specifiers/dir-with-main'))};`,
// Notice the trailing slash
`import success, { explicit, implicit, implicitModule } from ${JSON.stringify(fixtures.fileURL('es-module-specifiers/'))};`,
'strictEqual(commonjs, "commonjs");',
'strictEqual(module, "module");',
'strictEqual(main, "main");',
'strictEqual(success, "success");',
'strictEqual(explicit, "esm");',
'strictEqual(implicit, "cjs");',
Expand Down

0 comments on commit 8ec7bfd

Please sign in to comment.