diff --git a/packages/ses/test/hermes-smoke.js b/packages/ses/test/hermes-smoke.js index f6d9e0b857..4211f6e43b 100644 --- a/packages/ses/test/hermes-smoke.js +++ b/packages/ses/test/hermes-smoke.js @@ -1,5 +1,7 @@ -import '../dist/ses.cjs'; -import '../src/assert-shim.js'; +// TODO: equivalent of: +// import '../dist/ses.cjs'; +// import '../src/assert-shim.js'; +// Since Hermes has no native support for I/O // Test lockdown @@ -12,14 +14,14 @@ const c = new Compartment(); c.evaluate('1+1'); c.evaluate("const c2 = new Compartment(); c2.evaluate('1+2')"); -// Test importHook and resolveHook (non-ESM) +// Test importHook and resolveHook // https://github.com/facebook/hermes/blob/main/doc/Features.md // In Progress: ES modules (`import` and `export`) const resolveHook = ''; -const importHook = async () => { +async function importHook () { return { imports: [], exports: ['meaning'], @@ -33,9 +35,9 @@ const compartment = new Compartment({}, {}, { resolveHook, importHook }); const module = compartment.module('.'); -const { - namespace: { _meaning }, -} = await compartment.import('.'); +// const { +// namespace: { _meaning }, +// } = await compartment.import('.'); assert(module); // t.is(meaning, 42, 'exports seen');