Skip to content

Commit 5e52b69

Browse files
committed
Make the node-template type=module
1 parent e54e553 commit 5e52b69

16 files changed

Lines changed: 10 additions & 9 deletions

smoke-tests/node-template/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22
"name": "ember-test-node-template",
33
"version": "0.0.0",
44
"private": true,
5+
"type": "module",
56
"description": "Node-focused smoke test template for ember-source",
67
"scripts": {
7-
"test:node": "node --import ./tests/node/helpers/register-loader.mjs --test tests/node/*.test.mjs"
8+
"test:node": "node --import ./tests/node/helpers/register-loader.js --test tests/node/*.test.js"
89
},
910
"dependencies": {
1011
"simple-dom": "^1.4.0",

smoke-tests/node-template/tests/node/app-boot.test.mjs renamed to smoke-tests/node-template/tests/node/app-boot.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { describe, test, beforeEach, afterEach } from 'node:test';
22
import assert from 'node:assert/strict';
3-
import { createAppContext } from './helpers/setup-app.mjs';
4-
import { assertHtmlMatches } from './helpers/assert-html-matches.mjs';
3+
import { createAppContext } from './helpers/setup-app.js';
4+
import { assertHtmlMatches } from './helpers/assert-html-matches.js';
55

66
describe('App Boot', () => {
77
let ctx;

smoke-tests/node-template/tests/node/component-rendering.test.mjs renamed to smoke-tests/node-template/tests/node/component-rendering.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { describe, test, beforeEach, afterEach } from 'node:test';
22
import assert from 'node:assert/strict';
3-
import { createComponentContext } from './helpers/setup-component.mjs';
3+
import { createComponentContext } from './helpers/setup-component.js';
44

55
describe('Components can be rendered without a DOM dependency', () => {
66
let ctx;

smoke-tests/node-template/tests/node/fastboot-sandbox.test.mjs renamed to smoke-tests/node-template/tests/node/fastboot-sandbox.test.js

File renamed without changes.

smoke-tests/node-template/tests/node/helpers/assert-html-matches.mjs renamed to smoke-tests/node-template/tests/node/helpers/assert-html-matches.js

File renamed without changes.

smoke-tests/node-template/tests/node/helpers/build-owner.mjs renamed to smoke-tests/node-template/tests/node/helpers/build-owner.js

File renamed without changes.

smoke-tests/node-template/tests/node/helpers/load-template-compiler.mjs renamed to smoke-tests/node-template/tests/node/helpers/load-template-compiler.js

File renamed without changes.

smoke-tests/node-template/tests/node/helpers/macros-shim.mjs renamed to smoke-tests/node-template/tests/node/helpers/macros-shim.js

File renamed without changes.

smoke-tests/node-template/tests/node/helpers/register-loader.mjs renamed to smoke-tests/node-template/tests/node/helpers/register-loader.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@
22
* Node.js module loader hook that intercepts '@embroider/macros' imports
33
* and redirects them to our local shim.
44
*
5-
* Usage: node --import ./tests/node/helpers/register-loader.mjs --test ...
5+
* Usage: node --import ./tests/node/helpers/register-loader.js --test ...
66
*/
77
import { register } from 'node:module';
88
import { fileURLToPath, pathToFileURL } from 'node:url';
99
import { dirname, resolve } from 'node:path';
1010

1111
const __dirname = dirname(fileURLToPath(import.meta.url));
12-
const shimPath = resolve(__dirname, 'macros-shim.mjs');
12+
const shimPath = resolve(__dirname, 'macros-shim.js');
1313
const shimURL = pathToFileURL(shimPath).href;
1414

1515
register('data:text/javascript,' + encodeURIComponent(`

smoke-tests/node-template/tests/node/helpers/setup-app.mjs renamed to smoke-tests/node-template/tests/node/helpers/setup-app.js

File renamed without changes.

0 commit comments

Comments
 (0)