11cb0ef41Sopenharmony_ciimport { mustNotCall } from '../common/index.mjs'; 21cb0ef41Sopenharmony_ciimport * as fixtures from '../common/fixtures.mjs'; 31cb0ef41Sopenharmony_ciimport assert from 'assert'; 41cb0ef41Sopenharmony_ci 51cb0ef41Sopenharmony_ciObject.defineProperty(Error.prototype, 'url', { 61cb0ef41Sopenharmony_ci get: mustNotCall('get %Error.prototype%.url'), 71cb0ef41Sopenharmony_ci set: mustNotCall('set %Error.prototype%.url'), 81cb0ef41Sopenharmony_ci}); 91cb0ef41Sopenharmony_ciObject.defineProperty(Object.prototype, 'url', { 101cb0ef41Sopenharmony_ci get: mustNotCall('get %Object.prototype%.url'), 111cb0ef41Sopenharmony_ci set: mustNotCall('set %Object.prototype%.url'), 121cb0ef41Sopenharmony_ci}); 131cb0ef41Sopenharmony_ci 141cb0ef41Sopenharmony_ciawait assert.rejects(import('../fixtures/es-modules/pjson-main'), { 151cb0ef41Sopenharmony_ci code: 'ERR_UNSUPPORTED_DIR_IMPORT', 161cb0ef41Sopenharmony_ci url: fixtures.fileURL('es-modules/pjson-main').href, 171cb0ef41Sopenharmony_ci}); 181cb0ef41Sopenharmony_ci 191cb0ef41Sopenharmony_ciassert.deepStrictEqual( 201cb0ef41Sopenharmony_ci { ...await import('../fixtures/es-modules/pjson-main/main.mjs') }, 211cb0ef41Sopenharmony_ci { main: 'main' }, 221cb0ef41Sopenharmony_ci); 23