11cb0ef41Sopenharmony_ci'use strict'; 21cb0ef41Sopenharmony_ci 31cb0ef41Sopenharmony_ciconst { spawnPromisified } = require('../common'); 41cb0ef41Sopenharmony_ciconst fixtures = require('../common/fixtures.js'); 51cb0ef41Sopenharmony_ciconst assert = require('node:assert'); 61cb0ef41Sopenharmony_ciconst { execPath } = require('node:process'); 71cb0ef41Sopenharmony_ciconst { describe, it } = require('node:test'); 81cb0ef41Sopenharmony_ci 91cb0ef41Sopenharmony_ci 101cb0ef41Sopenharmony_ciconst entry = fixtures.path('/es-modules/builtin-imports-case.mjs'); 111cb0ef41Sopenharmony_ci 121cb0ef41Sopenharmony_cidescribe('ESM: importing builtins & CJS', () => { 131cb0ef41Sopenharmony_ci it('should work', async () => { 141cb0ef41Sopenharmony_ci const { code, signal, stdout } = await spawnPromisified(execPath, [entry]); 151cb0ef41Sopenharmony_ci 161cb0ef41Sopenharmony_ci assert.strictEqual(code, 0); 171cb0ef41Sopenharmony_ci assert.strictEqual(signal, null); 181cb0ef41Sopenharmony_ci assert.strictEqual(stdout, 'ok\n'); 191cb0ef41Sopenharmony_ci }); 201cb0ef41Sopenharmony_ci}); 21