From e8305a79205980a9228b8347708b74765f164555 Mon Sep 17 00:00:00 2001 From: Leo Balter Date: Wed, 3 Oct 2018 13:39:16 -0400 Subject: [PATCH] Regenerate tests --- ...mport-catch-eval-rqstd-abrupt-typeerror.js | 40 ------------ ...import-catch-eval-rqstd-abrupt-urierror.js | 40 ------------ ...rt-catch-instn-iee-err-ambiguous-import.js | 61 ------------------- ...-do-import-catch-instn-iee-err-circular.js | 50 --------------- ...do-import-catch-instn-iee-err-not-found.js | 49 --------------- ...ed-do-while-eval-rqstd-abrupt-typeerror.js | 2 +- ...ted-do-while-eval-rqstd-abrupt-urierror.js | 2 +- ...do-while-instn-iee-err-ambiguous-import.js | 2 +- .../nested-do-while-instn-iee-err-circular.js | 2 +- ...nested-do-while-instn-iee-err-not-found.js | 2 +- ...mport-catch-eval-rqstd-abrupt-typeerror.js | 38 ------------ ...import-catch-eval-rqstd-abrupt-urierror.js | 38 ------------ ...rt-catch-instn-iee-err-ambiguous-import.js | 59 ------------------ ...ock-import-catch-instn-iee-err-circular.js | 48 --------------- ...ck-import-catch-instn-iee-err-not-found.js | 47 -------------- ...-await-eval-gtbdng-indirect-update-dflt.js | 4 +- ...tion-await-eval-gtbndng-indirect-update.js | 4 +- ...ed-async-function-await-returns-promise.js | 4 +- ...nction-eval-gtbdng-indirect-update-dflt.js | 1 - ...c-function-eval-gtbndng-indirect-update.js | 1 - ...-await-eval-gtbdng-indirect-update-dflt.js | 14 ++--- ...turn-await-eval-gtbndng-indirect-update.js | 28 ++++----- ...c-function-return-await-returns-promise.js | 12 ++-- .../nested-async-function-returns-promise.js | 1 - ...t-then-eval-gtbdng-indirect-update-dflt.js | 46 -------------- ...mport-then-eval-gtbndng-indirect-update.js | 54 ---------------- .../nested-do-import-then-returns-promise.js | 33 ---------- ...-while-eval-gtbdng-indirect-update-dflt.js | 2 +- ...d-do-while-eval-gtbndng-indirect-update.js | 2 +- .../nested-do-while-returns-promise.js | 2 +- ...t-then-eval-gtbdng-indirect-update-dflt.js | 44 ------------- ...mport-then-eval-gtbndng-indirect-update.js | 52 ---------------- ...beled-block-import-then-returns-promise.js | 31 ---------- ...ted-arrow-assignment-expr-not-optional.js} | 5 +- ...xpression-assignment-expr-not-optional.js} | 5 +- ...ted-block-assignment-expr-not-optional.js} | 5 +- ...k-labeled-assignment-expr-not-optional.js} | 5 +- .../nested-do-empty-args-early-error.js | 40 ------------ ...-do-while-assignment-expr-not-optional.js} | 7 +-- ...sted-else-assignment-expr-not-optional.js} | 5 +- ...braceless-assignment-expr-not-optional.js} | 5 +- ...-function-assignment-expr-not-optional.js} | 5 +- ...on-return-assignment-expr-not-optional.js} | 5 +- ...nested-if-assignment-expr-not-optional.js} | 5 +- ...braceless-assignment-expr-not-optional.js} | 5 +- ...ed-labeled-block-empty-args-early-error.js | 38 ------------ ...ted-while-assignment-expr-not-optional.js} | 5 +- ...top-level-assignment-expr-not-optional.js} | 5 +- .../syntax/valid/nested-do-empty-str-arg.js | 29 --------- .../valid/nested-do-while-empty-str-arg.js | 2 +- .../nested-labeled-block-empty-str-arg.js | 27 -------- 51 files changed, 69 insertions(+), 949 deletions(-) delete mode 100644 test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-typeerror.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-urierror.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-ambiguous-import.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-circular.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-not-found.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-typeerror.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-urierror.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-ambiguous-import.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-circular.js delete mode 100644 test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-not-found.js delete mode 100644 test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbdng-indirect-update-dflt.js delete mode 100644 test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbndng-indirect-update.js delete mode 100644 test/language/module-code/dynamic-import/nested-do-import-then-returns-promise.js delete mode 100644 test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbdng-indirect-update-dflt.js delete mode 100644 test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbndng-indirect-update.js delete mode 100644 test/language/module-code/dynamic-import/nested-labeled-block-import-then-returns-promise.js rename test/language/module-code/dynamic-import/syntax/invalid/{nested-arrow-empty-args-early-error.js => nested-arrow-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-arrow-assignment-expression-empty-args-early-error.js => nested-arrow-assignment-expression-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-block-empty-args-early-error.js => nested-block-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-block-labeled-empty-args-early-error.js => nested-block-labeled-assignment-expr-not-optional.js} (91%) delete mode 100644 test/language/module-code/dynamic-import/syntax/invalid/nested-do-empty-args-early-error.js rename test/language/module-code/dynamic-import/syntax/invalid/{nested-do-while-empty-args-early-error.js => nested-do-while-assignment-expr-not-optional.js} (89%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-else-empty-args-early-error.js => nested-else-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-else-braceless-empty-args-early-error.js => nested-else-braceless-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-function-empty-args-early-error.js => nested-function-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-function-return-empty-args-early-error.js => nested-function-return-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-if-empty-args-early-error.js => nested-if-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{nested-if-braceless-empty-args-early-error.js => nested-if-braceless-assignment-expr-not-optional.js} (91%) delete mode 100644 test/language/module-code/dynamic-import/syntax/invalid/nested-labeled-block-empty-args-early-error.js rename test/language/module-code/dynamic-import/syntax/invalid/{nested-while-empty-args-early-error.js => nested-while-assignment-expr-not-optional.js} (91%) rename test/language/module-code/dynamic-import/syntax/invalid/{top-level-empty-args-early-error.js => top-level-assignment-expr-not-optional.js} (83%) delete mode 100644 test/language/module-code/dynamic-import/syntax/valid/nested-do-empty-str-arg.js delete mode 100644 test/language/module-code/dynamic-import/syntax/valid/nested-labeled-block-empty-str-arg.js diff --git a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-typeerror.js b/test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-typeerror.js deleted file mode 100644 index ab70de8b07..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-typeerror.js +++ /dev/null @@ -1,40 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-rqstd-abrupt-typeerror.case -// - src/dynamic-import/catch/nested-do.template -/*--- -description: Abrupt completion during module evaluation precludes further evaluation (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 6. For each String required that is an element of - module.[[RequestedModules]] do, - a. Let requiredModule be ? HostResolveImportedModule(module, required). - b. Perform ? requiredModule.ModuleEvaluation(). - ----*/ - -let x = 0; -do { - x++; - import('./eval-rqstd-abrupt-err-type_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'TypeError'); - - }).then($DONE, $DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-urierror.js b/test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-urierror.js deleted file mode 100644 index f5a6bef0bf..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-eval-rqstd-abrupt-urierror.js +++ /dev/null @@ -1,40 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-rqstd-abrupt-urierror.case -// - src/dynamic-import/catch/nested-do.template -/*--- -description: Abrupt completion during module evaluation precludes further evaluation (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 6. For each String required that is an element of - module.[[RequestedModules]] do, - a. Let requiredModule be ? HostResolveImportedModule(module, required). - b. Perform ? requiredModule.ModuleEvaluation(). - ----*/ - -let x = 0; -do { - x++; - import('./eval-rqstd-abrupt-err-uri_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'URIError'); - - }).then($DONE, $DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-ambiguous-import.js b/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-ambiguous-import.js deleted file mode 100644 index 4c883d3b69..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-ambiguous-import.js +++ /dev/null @@ -1,61 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/instn-iee-err-ambiguous-import.case -// - src/dynamic-import/catch/nested-do.template -/*--- -description: IndirectExportEntries validation - ambiguous imported bindings (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do - a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »). - b. If resolution is null or resolution is "ambiguous", throw a - SyntaxError exception. - [...] - - 15.2.1.16.3 ResolveExport - - [...] - 9. Let starResolution be null. - 10. For each ExportEntry Record e in module.[[StarExportEntries]], do - a. Let importedModule be ? HostResolveImportedModule(module, - e.[[ModuleRequest]]). - b. Let resolution be ? importedModule.ResolveExport(exportName, - resolveSet, exportStarSet). - c. If resolution is "ambiguous", return "ambiguous". - d. If resolution is not null, then - i. If starResolution is null, let starResolution be resolution. - ii. Else, - 1. Assert: there is more than one * import that includes the - requested name. - 2. If resolution.[[Module]] and starResolution.[[Module]] are - not the same Module Record or - SameValue(resolution.[[BindingName]], - starResolution.[[BindingName]]) is false, return "ambiguous". - ----*/ - -let x = 0; -do { - x++; - import('./instn-iee-err-ambiguous-export.js').catch(error => { - - assert.sameValue(error.name, 'SyntaxError'); - - }).then($DONE, $DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-circular.js b/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-circular.js deleted file mode 100644 index 10f8d95268..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-circular.js +++ /dev/null @@ -1,50 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/instn-iee-err-circular.case -// - src/dynamic-import/catch/nested-do.template -/*--- -description: IndirectExportEntries validation - circular imported bindings (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do - a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »). - b. If resolution is null or resolution is "ambiguous", throw a - SyntaxError exception. - [...] - - 15.2.1.16.3 ResolveExport - - [...] - 2. For each Record {[[Module]], [[ExportName]]} r in resolveSet, do: - a. If module and r.[[Module]] are the same Module Record and - SameValue(exportName, r.[[ExportName]]) is true, then - i. Assert: this is a circular import request. - ii. Return null. - ----*/ - -let x = 0; -do { - x++; - import('./instn-iee-err-circular-1_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'SyntaxError'); - - }).then($DONE, $DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-not-found.js b/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-not-found.js deleted file mode 100644 index 6d12fb6738..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-do-import-catch-instn-iee-err-not-found.js +++ /dev/null @@ -1,49 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/instn-iee-err-not-found.case -// - src/dynamic-import/catch/nested-do.template -/*--- -description: IndirectExportEntries validation - undefined imported bindings (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do - a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »). - b. If resolution is null or resolution is "ambiguous", throw a - SyntaxError exception. - [...] - - 15.2.1.16.3 ResolveExport - - [...] - 9. Let starResolution be null. - 10. For each ExportEntry Record e in module.[[StarExportEntries]], do - [...] - 11. Return starResolution. - ----*/ - -let x = 0; -do { - x++; - import('./instn-iee-err-not-found-empty_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'SyntaxError'); - - }).then($DONE, $DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-typeerror.js b/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-typeerror.js index 59cff22cd0..18f0599a6a 100644 --- a/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-typeerror.js +++ b/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-typeerror.js @@ -2,7 +2,7 @@ // - src/dynamic-import/eval-rqstd-abrupt-typeerror.case // - src/dynamic-import/catch/nested-do-while.template /*--- -description: Abrupt completion during module evaluation precludes further evaluation (nested do syntax) +description: Abrupt completion during module evaluation precludes further evaluation (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-urierror.js b/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-urierror.js index 15625a6c89..6e42f6d2ba 100644 --- a/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-urierror.js +++ b/test/language/module-code/dynamic-import/catch/nested-do-while-eval-rqstd-abrupt-urierror.js @@ -2,7 +2,7 @@ // - src/dynamic-import/eval-rqstd-abrupt-urierror.case // - src/dynamic-import/catch/nested-do-while.template /*--- -description: Abrupt completion during module evaluation precludes further evaluation (nested do syntax) +description: Abrupt completion during module evaluation precludes further evaluation (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-ambiguous-import.js b/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-ambiguous-import.js index 8f96eecaa7..9c971e2380 100644 --- a/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-ambiguous-import.js +++ b/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-ambiguous-import.js @@ -2,7 +2,7 @@ // - src/dynamic-import/instn-iee-err-ambiguous-import.case // - src/dynamic-import/catch/nested-do-while.template /*--- -description: IndirectExportEntries validation - ambiguous imported bindings (nested do syntax) +description: IndirectExportEntries validation - ambiguous imported bindings (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-circular.js b/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-circular.js index 24616f24c5..84f8926624 100644 --- a/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-circular.js +++ b/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-circular.js @@ -2,7 +2,7 @@ // - src/dynamic-import/instn-iee-err-circular.case // - src/dynamic-import/catch/nested-do-while.template /*--- -description: IndirectExportEntries validation - circular imported bindings (nested do syntax) +description: IndirectExportEntries validation - circular imported bindings (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-not-found.js b/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-not-found.js index 1b9e554fe3..1a8917f490 100644 --- a/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-not-found.js +++ b/test/language/module-code/dynamic-import/catch/nested-do-while-instn-iee-err-not-found.js @@ -2,7 +2,7 @@ // - src/dynamic-import/instn-iee-err-not-found.case // - src/dynamic-import/catch/nested-do-while.template /*--- -description: IndirectExportEntries validation - undefined imported bindings (nested do syntax) +description: IndirectExportEntries validation - undefined imported bindings (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-typeerror.js b/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-typeerror.js deleted file mode 100644 index e2a7ff0d9a..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-typeerror.js +++ /dev/null @@ -1,38 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-rqstd-abrupt-typeerror.case -// - src/dynamic-import/catch/nested-labeled-block.template -/*--- -description: Abrupt completion during module evaluation precludes further evaluation (nested labeled block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 6. For each String required that is an element of - module.[[RequestedModules]] do, - a. Let requiredModule be ? HostResolveImportedModule(module, required). - b. Perform ? requiredModule.ModuleEvaluation(). - ----*/ - -{ - import('./eval-rqstd-abrupt-err-type_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'TypeError'); - - }).then($DONE, $DONE); -}; diff --git a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-urierror.js b/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-urierror.js deleted file mode 100644 index dd94cb1bd9..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-eval-rqstd-abrupt-urierror.js +++ /dev/null @@ -1,38 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-rqstd-abrupt-urierror.case -// - src/dynamic-import/catch/nested-labeled-block.template -/*--- -description: Abrupt completion during module evaluation precludes further evaluation (nested labeled block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 6. For each String required that is an element of - module.[[RequestedModules]] do, - a. Let requiredModule be ? HostResolveImportedModule(module, required). - b. Perform ? requiredModule.ModuleEvaluation(). - ----*/ - -{ - import('./eval-rqstd-abrupt-err-uri_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'URIError'); - - }).then($DONE, $DONE); -}; diff --git a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-ambiguous-import.js b/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-ambiguous-import.js deleted file mode 100644 index 3e724f8655..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-ambiguous-import.js +++ /dev/null @@ -1,59 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/instn-iee-err-ambiguous-import.case -// - src/dynamic-import/catch/nested-labeled-block.template -/*--- -description: IndirectExportEntries validation - ambiguous imported bindings (nested labeled block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do - a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »). - b. If resolution is null or resolution is "ambiguous", throw a - SyntaxError exception. - [...] - - 15.2.1.16.3 ResolveExport - - [...] - 9. Let starResolution be null. - 10. For each ExportEntry Record e in module.[[StarExportEntries]], do - a. Let importedModule be ? HostResolveImportedModule(module, - e.[[ModuleRequest]]). - b. Let resolution be ? importedModule.ResolveExport(exportName, - resolveSet, exportStarSet). - c. If resolution is "ambiguous", return "ambiguous". - d. If resolution is not null, then - i. If starResolution is null, let starResolution be resolution. - ii. Else, - 1. Assert: there is more than one * import that includes the - requested name. - 2. If resolution.[[Module]] and starResolution.[[Module]] are - not the same Module Record or - SameValue(resolution.[[BindingName]], - starResolution.[[BindingName]]) is false, return "ambiguous". - ----*/ - -{ - import('./instn-iee-err-ambiguous-export.js').catch(error => { - - assert.sameValue(error.name, 'SyntaxError'); - - }).then($DONE, $DONE); -}; diff --git a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-circular.js b/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-circular.js deleted file mode 100644 index b03308b74c..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-circular.js +++ /dev/null @@ -1,48 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/instn-iee-err-circular.case -// - src/dynamic-import/catch/nested-labeled-block.template -/*--- -description: IndirectExportEntries validation - circular imported bindings (nested labeled block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do - a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »). - b. If resolution is null or resolution is "ambiguous", throw a - SyntaxError exception. - [...] - - 15.2.1.16.3 ResolveExport - - [...] - 2. For each Record {[[Module]], [[ExportName]]} r in resolveSet, do: - a. If module and r.[[Module]] are the same Module Record and - SameValue(exportName, r.[[ExportName]]) is true, then - i. Assert: this is a circular import request. - ii. Return null. - ----*/ - -{ - import('./instn-iee-err-circular-1_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'SyntaxError'); - - }).then($DONE, $DONE); -}; diff --git a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-not-found.js b/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-not-found.js deleted file mode 100644 index 6531f8894a..0000000000 --- a/test/language/module-code/dynamic-import/catch/nested-labeled-block-import-catch-instn-iee-err-not-found.js +++ /dev/null @@ -1,47 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/instn-iee-err-not-found.case -// - src/dynamic-import/catch/nested-labeled-block.template -/*--- -description: IndirectExportEntries validation - undefined imported bindings (nested labeled block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - [...] - 9. For each ExportEntry Record e in module.[[IndirectExportEntries]], do - a. Let resolution be ? module.ResolveExport(e.[[ExportName]], « », « »). - b. If resolution is null or resolution is "ambiguous", throw a - SyntaxError exception. - [...] - - 15.2.1.16.3 ResolveExport - - [...] - 9. Let starResolution be null. - 10. For each ExportEntry Record e in module.[[StarExportEntries]], do - [...] - 11. Return starResolution. - ----*/ - -{ - import('./instn-iee-err-not-found-empty_FIXTURE.js').catch(error => { - - assert.sameValue(error.name, 'SyntaxError'); - - }).then($DONE, $DONE); -}; diff --git a/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbdng-indirect-update-dflt.js b/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbdng-indirect-update-dflt.js index b05617ab97..dc3ae7cf15 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbdng-indirect-update-dflt.js +++ b/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbdng-indirect-update-dflt.js @@ -40,7 +40,7 @@ async function f() { assert.sameValue(imported.default(), 1); assert.sameValue(imported.default, 2); - }).then($DONE, $DONE).catch($DONE); + }); } -f(); +f().then($DONE, $DONE).catch($DONE); diff --git a/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbndng-indirect-update.js b/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbndng-indirect-update.js index 08b33e5219..709f3cb835 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbndng-indirect-update.js +++ b/test/language/module-code/dynamic-import/nested-async-function-await-eval-gtbndng-indirect-update.js @@ -48,7 +48,7 @@ async function f() { assert.sameValue(imported.x, 2); - }).then($DONE, $DONE).catch($DONE); + }); } -f(); +f().then($DONE, $DONE).catch($DONE); diff --git a/test/language/module-code/dynamic-import/nested-async-function-await-returns-promise.js b/test/language/module-code/dynamic-import/nested-async-function-await-returns-promise.js index 5540b6ac75..065feb806f 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-await-returns-promise.js +++ b/test/language/module-code/dynamic-import/nested-async-function-await-returns-promise.js @@ -27,7 +27,7 @@ async function f() { assert.sameValue(imported.x, 1); - }).then($DONE, $DONE).catch($DONE); + }); } -f(); +f().then($DONE, $DONE).catch($DONE); diff --git a/test/language/module-code/dynamic-import/nested-async-function-eval-gtbdng-indirect-update-dflt.js b/test/language/module-code/dynamic-import/nested-async-function-eval-gtbdng-indirect-update-dflt.js index 510a62533d..86a1d4bc4b 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-eval-gtbdng-indirect-update-dflt.js +++ b/test/language/module-code/dynamic-import/nested-async-function-eval-gtbdng-indirect-update-dflt.js @@ -44,4 +44,3 @@ async function f() { } f(); - diff --git a/test/language/module-code/dynamic-import/nested-async-function-eval-gtbndng-indirect-update.js b/test/language/module-code/dynamic-import/nested-async-function-eval-gtbndng-indirect-update.js index f23ca5c1ae..6cd1363668 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-eval-gtbndng-indirect-update.js +++ b/test/language/module-code/dynamic-import/nested-async-function-eval-gtbndng-indirect-update.js @@ -52,4 +52,3 @@ async function f() { } f(); - diff --git a/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbdng-indirect-update-dflt.js b/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbdng-indirect-update-dflt.js index 4545fd0ceb..67533783dc 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbdng-indirect-update-dflt.js +++ b/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbdng-indirect-update-dflt.js @@ -35,12 +35,12 @@ info: | ---*/ async function f() { - return await import('./eval-gtbndng-indirect-update-dflt_FIXTURE.js').then(imported => { - - assert.sameValue(imported.default(), 1); - assert.sameValue(imported.default, 2); - - }).then($DONE, $DONE).catch($DONE); + return await import('./eval-gtbndng-indirect-update-dflt_FIXTURE.js'); } -f(); +f().then(imported => { + + assert.sameValue(imported.default(), 1); + assert.sameValue(imported.default, 2); + +}).then($DONE, $DONE).catch($DONE); diff --git a/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbndng-indirect-update.js b/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbndng-indirect-update.js index 86128cbf8e..51efea8fe9 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbndng-indirect-update.js +++ b/test/language/module-code/dynamic-import/nested-async-function-return-await-eval-gtbndng-indirect-update.js @@ -36,19 +36,19 @@ info: | ---*/ async function f() { - return await import('./eval-gtbndng-indirect-update_FIXTURE.js').then(imported => { - - assert.sameValue(imported.x, 1); - - // This function is exposed on the global scope (instead of as an exported - // binding) in order to avoid possible false positives from assuming correct - // behavior of the semantics under test. - fnGlobalObject().test262update(); - - assert.sameValue(imported.x, 2); - - - }).then($DONE, $DONE).catch($DONE); + return await import('./eval-gtbndng-indirect-update_FIXTURE.js'); } -f(); +f().then(imported => { + + assert.sameValue(imported.x, 1); + + // This function is exposed on the global scope (instead of as an exported + // binding) in order to avoid possible false positives from assuming correct + // behavior of the semantics under test. + fnGlobalObject().test262update(); + + assert.sameValue(imported.x, 2); + + +}).then($DONE, $DONE).catch($DONE); diff --git a/test/language/module-code/dynamic-import/nested-async-function-return-await-returns-promise.js b/test/language/module-code/dynamic-import/nested-async-function-return-await-returns-promise.js index 2c950986a0..135a98225e 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-return-await-returns-promise.js +++ b/test/language/module-code/dynamic-import/nested-async-function-return-await-returns-promise.js @@ -23,11 +23,11 @@ info: | ---*/ async function f() { - return await import('./dynamic-import-module_FIXTURE.js').then(imported => { - - assert.sameValue(imported.x, 1); - - }).then($DONE, $DONE).catch($DONE); + return await import('./dynamic-import-module_FIXTURE.js'); } -f(); +f().then(imported => { + + assert.sameValue(imported.x, 1); + +}).then($DONE, $DONE).catch($DONE); diff --git a/test/language/module-code/dynamic-import/nested-async-function-returns-promise.js b/test/language/module-code/dynamic-import/nested-async-function-returns-promise.js index 14a97dfab3..435b3e0d3e 100644 --- a/test/language/module-code/dynamic-import/nested-async-function-returns-promise.js +++ b/test/language/module-code/dynamic-import/nested-async-function-returns-promise.js @@ -31,4 +31,3 @@ async function f() { } f(); - diff --git a/test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbdng-indirect-update-dflt.js b/test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbdng-indirect-update-dflt.js deleted file mode 100644 index 3948afe3d9..0000000000 --- a/test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbdng-indirect-update-dflt.js +++ /dev/null @@ -1,46 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-gtbdng-indirect-update-dflt.case -// - src/dynamic-import/default/nested-do.template -/*--- -description: Modifications to default binding that occur after dependency has been evaluated are reflected in local binding (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - GetBindingValue (N, S) - - [...] - 3. If the binding for N is an indirect binding, then - a. Let M and N2 be the indirection values provided when this binding for - N was created. - b. Let targetEnv be M.[[Environment]]. - c. If targetEnv is undefined, throw a ReferenceError exception. - d. Let targetER be targetEnv's EnvironmentRecord. - e. Return ? targetER.GetBindingValue(N2, S). - ----*/ - -let x = 0; -do { - x++; - import('./eval-gtbndng-indirect-update-dflt_FIXTURE.js').then(imported => { - - assert.sameValue(imported.default(), 1); - assert.sameValue(imported.default, 2); - - }).then($DONE, $DONE).catch($DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbndng-indirect-update.js b/test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbndng-indirect-update.js deleted file mode 100644 index a02175e900..0000000000 --- a/test/language/module-code/dynamic-import/nested-do-import-then-eval-gtbndng-indirect-update.js +++ /dev/null @@ -1,54 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-gtbndng-indirect-update.case -// - src/dynamic-import/default/nested-do.template -/*--- -description: Modifications to named bindings that occur after dependency has been evaluated are reflected in local binding (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -includes: [fnGlobalObject.js] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - GetBindingValue (N, S) - - [...] - 3. If the binding for N is an indirect binding, then - a. Let M and N2 be the indirection values provided when this binding for - N was created. - b. Let targetEnv be M.[[Environment]]. - c. If targetEnv is undefined, throw a ReferenceError exception. - d. Let targetER be targetEnv's EnvironmentRecord. - e. Return ? targetER.GetBindingValue(N2, S). - ----*/ - -let x = 0; -do { - x++; - import('./eval-gtbndng-indirect-update_FIXTURE.js').then(imported => { - - assert.sameValue(imported.x, 1); - - // This function is exposed on the global scope (instead of as an exported - // binding) in order to avoid possible false positives from assuming correct - // behavior of the semantics under test. - fnGlobalObject().test262update(); - - assert.sameValue(imported.x, 2); - - - }).then($DONE, $DONE).catch($DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/nested-do-import-then-returns-promise.js b/test/language/module-code/dynamic-import/nested-do-import-then-returns-promise.js deleted file mode 100644 index 337655e7eb..0000000000 --- a/test/language/module-code/dynamic-import/nested-do-import-then-returns-promise.js +++ /dev/null @@ -1,33 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/returns-promise.case -// - src/dynamic-import/default/nested-do.template -/*--- -description: Dynamic import() returns a Promise object. (nested do) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - ----*/ - -let x = 0; -do { - x++; - import('./dynamic-import-module_FIXTURE.js').then(imported => { - - assert.sameValue(imported.x, 1); - - }).then($DONE, $DONE).catch($DONE); -} while (!x); diff --git a/test/language/module-code/dynamic-import/nested-do-while-eval-gtbdng-indirect-update-dflt.js b/test/language/module-code/dynamic-import/nested-do-while-eval-gtbdng-indirect-update-dflt.js index 4070bf203a..e0e379308b 100644 --- a/test/language/module-code/dynamic-import/nested-do-while-eval-gtbdng-indirect-update-dflt.js +++ b/test/language/module-code/dynamic-import/nested-do-while-eval-gtbdng-indirect-update-dflt.js @@ -2,7 +2,7 @@ // - src/dynamic-import/eval-gtbdng-indirect-update-dflt.case // - src/dynamic-import/default/nested-do-while.template /*--- -description: Modifications to default binding that occur after dependency has been evaluated are reflected in local binding (nested do syntax) +description: Modifications to default binding that occur after dependency has been evaluated are reflected in local binding (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/nested-do-while-eval-gtbndng-indirect-update.js b/test/language/module-code/dynamic-import/nested-do-while-eval-gtbndng-indirect-update.js index ccad263d52..dc299c1526 100644 --- a/test/language/module-code/dynamic-import/nested-do-while-eval-gtbndng-indirect-update.js +++ b/test/language/module-code/dynamic-import/nested-do-while-eval-gtbndng-indirect-update.js @@ -2,7 +2,7 @@ // - src/dynamic-import/eval-gtbndng-indirect-update.case // - src/dynamic-import/default/nested-do-while.template /*--- -description: Modifications to named bindings that occur after dependency has been evaluated are reflected in local binding (nested do syntax) +description: Modifications to named bindings that occur after dependency has been evaluated are reflected in local binding (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/nested-do-while-returns-promise.js b/test/language/module-code/dynamic-import/nested-do-while-returns-promise.js index ddd1c1cc6e..1907481f2c 100644 --- a/test/language/module-code/dynamic-import/nested-do-while-returns-promise.js +++ b/test/language/module-code/dynamic-import/nested-do-while-returns-promise.js @@ -2,7 +2,7 @@ // - src/dynamic-import/returns-promise.case // - src/dynamic-import/default/nested-do-while.template /*--- -description: Dynamic import() returns a Promise object. (nested do syntax) +description: Dynamic import() returns a Promise object. (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, async] diff --git a/test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbdng-indirect-update-dflt.js b/test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbdng-indirect-update-dflt.js deleted file mode 100644 index 7f0313a530..0000000000 --- a/test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbdng-indirect-update-dflt.js +++ /dev/null @@ -1,44 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-gtbdng-indirect-update-dflt.case -// - src/dynamic-import/default/nested-labeled-block.template -/*--- -description: Modifications to default binding that occur after dependency has been evaluated are reflected in local binding (nested block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - GetBindingValue (N, S) - - [...] - 3. If the binding for N is an indirect binding, then - a. Let M and N2 be the indirection values provided when this binding for - N was created. - b. Let targetEnv be M.[[Environment]]. - c. If targetEnv is undefined, throw a ReferenceError exception. - d. Let targetER be targetEnv's EnvironmentRecord. - e. Return ? targetER.GetBindingValue(N2, S). - ----*/ - -{ - import('./eval-gtbndng-indirect-update-dflt_FIXTURE.js').then(imported => { - - assert.sameValue(imported.default(), 1); - assert.sameValue(imported.default, 2); - - }).then($DONE, $DONE).catch($DONE); -}; diff --git a/test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbndng-indirect-update.js b/test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbndng-indirect-update.js deleted file mode 100644 index 8a398830c7..0000000000 --- a/test/language/module-code/dynamic-import/nested-labeled-block-import-then-eval-gtbndng-indirect-update.js +++ /dev/null @@ -1,52 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/eval-gtbndng-indirect-update.case -// - src/dynamic-import/default/nested-labeled-block.template -/*--- -description: Modifications to named bindings that occur after dependency has been evaluated are reflected in local binding (nested block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -includes: [fnGlobalObject.js] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - GetBindingValue (N, S) - - [...] - 3. If the binding for N is an indirect binding, then - a. Let M and N2 be the indirection values provided when this binding for - N was created. - b. Let targetEnv be M.[[Environment]]. - c. If targetEnv is undefined, throw a ReferenceError exception. - d. Let targetER be targetEnv's EnvironmentRecord. - e. Return ? targetER.GetBindingValue(N2, S). - ----*/ - -{ - import('./eval-gtbndng-indirect-update_FIXTURE.js').then(imported => { - - assert.sameValue(imported.x, 1); - - // This function is exposed on the global scope (instead of as an exported - // binding) in order to avoid possible false positives from assuming correct - // behavior of the semantics under test. - fnGlobalObject().test262update(); - - assert.sameValue(imported.x, 2); - - - }).then($DONE, $DONE).catch($DONE); -}; diff --git a/test/language/module-code/dynamic-import/nested-labeled-block-import-then-returns-promise.js b/test/language/module-code/dynamic-import/nested-labeled-block-import-then-returns-promise.js deleted file mode 100644 index bdb6313a08..0000000000 --- a/test/language/module-code/dynamic-import/nested-labeled-block-import-then-returns-promise.js +++ /dev/null @@ -1,31 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/returns-promise.case -// - src/dynamic-import/default/nested-labeled-block.template -/*--- -description: Dynamic import() returns a Promise object. (nested block) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, async] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - ----*/ - -{ - import('./dynamic-import-module_FIXTURE.js').then(imported => { - - assert.sameValue(imported.x, 1); - - }).then($DONE, $DONE).catch($DONE); -}; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expr-not-optional.js index 41a4c52296..96a8bb6247 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-arrow.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expression-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expression-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expression-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expression-assignment-expr-not-optional.js index cb0d53404e..825bdf5c31 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expression-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-arrow-assignment-expression-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-arrow-assignment-expression.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested arrow syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-block-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-block-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-block-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-block-assignment-expr-not-optional.js index 759b1dde47..7867d2a4e9 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-block-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-block-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-block.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested block syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-block-labeled-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-block-labeled-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-block-labeled-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-block-labeled-assignment-expr-not-optional.js index 91b26736ef..6296b903bc 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-block-labeled-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-block-labeled-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-block-labeled.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested block syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-do-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-do-empty-args-early-error.js deleted file mode 100644 index 5fe6255bc0..0000000000 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-do-empty-args-early-error.js +++ /dev/null @@ -1,40 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case -// - src/dynamic-import/syntax/invalid/nested-do.template -/*--- -description: It's a SyntaxError if AssignmentExpression is omitted (nested do syntax) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, module] -negative: - phase: parse - type: SyntaxError -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - ImportCall : - import() - ----*/ - -throw "Test262: This statement should not be evaluated."; - -let x = 0; -do { - x++; - import(); -} while (!x); - -/* The params region intentionally empty */ diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-do-while-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-do-while-assignment-expr-not-optional.js similarity index 89% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-do-while-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-do-while-assignment-expr-not-optional.js index 9748868703..a1bbe92af5 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-do-while-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-do-while-assignment-expr-not-optional.js @@ -1,8 +1,8 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-do-while.template /*--- -description: It's a SyntaxError if AssignmentExpression is omitted (nested do syntax) +description: It's a SyntaxError if AssignmentExpression is omitted (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated, module] @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-else-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-else-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-else-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-else-assignment-expr-not-optional.js index d597e2bdbc..00dce8cf5c 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-else-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-else-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-else.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested else syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-else-braceless-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-else-braceless-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-else-braceless-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-else-braceless-assignment-expr-not-optional.js index f3281dcad6..1e691f817d 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-else-braceless-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-else-braceless-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-else-braceless.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested else syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-function-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-function-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-function-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-function-assignment-expr-not-optional.js index 80b501268e..4873ae664c 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-function-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-function-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-function.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested function syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-function-return-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-function-return-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-function-return-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-function-return-assignment-expr-not-optional.js index 0d2eab83f9..4a10c5de24 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-function-return-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-function-return-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-function-return.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested function syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-if-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-if-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-if-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-if-assignment-expr-not-optional.js index 352813c866..d0a3ff0af4 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-if-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-if-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-if.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested if syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-if-braceless-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-if-braceless-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-if-braceless-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-if-braceless-assignment-expr-not-optional.js index cf7b356ed4..af0f9caa7e 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-if-braceless-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-if-braceless-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-if-braceless.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested if syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-labeled-block-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-labeled-block-empty-args-early-error.js deleted file mode 100644 index 2bd53c18af..0000000000 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-labeled-block-empty-args-early-error.js +++ /dev/null @@ -1,38 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case -// - src/dynamic-import/syntax/invalid/nested-labeled.template -/*--- -description: It's a SyntaxError if AssignmentExpression is omitted (nested block syntax) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated, module] -negative: - phase: parse - type: SyntaxError -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - - - ImportCall : - import() - ----*/ - -throw "Test262: This statement should not be evaluated."; - -{ - import(); -}; - -/* The params region intentionally empty */ diff --git a/test/language/module-code/dynamic-import/syntax/invalid/nested-while-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/nested-while-assignment-expr-not-optional.js similarity index 91% rename from test/language/module-code/dynamic-import/syntax/invalid/nested-while-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/nested-while-assignment-expr-not-optional.js index e34b8be274..25cdafb6f5 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/nested-while-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/nested-while-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/nested-while.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (nested while syntax) @@ -25,8 +25,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/invalid/top-level-empty-args-early-error.js b/test/language/module-code/dynamic-import/syntax/invalid/top-level-assignment-expr-not-optional.js similarity index 83% rename from test/language/module-code/dynamic-import/syntax/invalid/top-level-empty-args-early-error.js rename to test/language/module-code/dynamic-import/syntax/invalid/top-level-assignment-expr-not-optional.js index 3a912622f6..32810c3d8b 100644 --- a/test/language/module-code/dynamic-import/syntax/invalid/top-level-empty-args-early-error.js +++ b/test/language/module-code/dynamic-import/syntax/invalid/top-level-assignment-expr-not-optional.js @@ -1,5 +1,5 @@ // This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-args-early-error.case +// - src/dynamic-import/assignment-expr-not-optional.case // - src/dynamic-import/syntax/invalid/top-level.template /*--- description: It's a SyntaxError if AssignmentExpression is omitted (top level syntax) @@ -15,8 +15,7 @@ info: | ImportCall : - import() - + import( AssignmentExpression[+In, ?Yield] ) ---*/ throw "Test262: This statement should not be evaluated."; diff --git a/test/language/module-code/dynamic-import/syntax/valid/nested-do-empty-str-arg.js b/test/language/module-code/dynamic-import/syntax/valid/nested-do-empty-str-arg.js deleted file mode 100644 index 508bc173d2..0000000000 --- a/test/language/module-code/dynamic-import/syntax/valid/nested-do-empty-str-arg.js +++ /dev/null @@ -1,29 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-str-arg.case -// - src/dynamic-import/syntax/valid/nested-do.template -/*--- -description: Calling import('') (nested do syntax) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - ----*/ - -let x = 0; -do { - x++; - import(''); -} while (!x); diff --git a/test/language/module-code/dynamic-import/syntax/valid/nested-do-while-empty-str-arg.js b/test/language/module-code/dynamic-import/syntax/valid/nested-do-while-empty-str-arg.js index 327864826d..ffc8debed7 100644 --- a/test/language/module-code/dynamic-import/syntax/valid/nested-do-while-empty-str-arg.js +++ b/test/language/module-code/dynamic-import/syntax/valid/nested-do-while-empty-str-arg.js @@ -2,7 +2,7 @@ // - src/dynamic-import/empty-str-arg.case // - src/dynamic-import/syntax/valid/nested-do-while.template /*--- -description: Calling import('') (nested do syntax) +description: Calling import('') (nested do while syntax) esid: sec-import-call-runtime-semantics-evaluation features: [dynamic-import] flags: [generated] diff --git a/test/language/module-code/dynamic-import/syntax/valid/nested-labeled-block-empty-str-arg.js b/test/language/module-code/dynamic-import/syntax/valid/nested-labeled-block-empty-str-arg.js deleted file mode 100644 index ee922977bd..0000000000 --- a/test/language/module-code/dynamic-import/syntax/valid/nested-labeled-block-empty-str-arg.js +++ /dev/null @@ -1,27 +0,0 @@ -// This file was procedurally generated from the following sources: -// - src/dynamic-import/empty-str-arg.case -// - src/dynamic-import/syntax/valid/nested-labeled.template -/*--- -description: Calling import('') (nested block syntax) -esid: sec-import-call-runtime-semantics-evaluation -features: [dynamic-import] -flags: [generated] -info: | - ImportCall : - import( AssignmentExpression ) - - 1. Let referencingScriptOrModule be ! GetActiveScriptOrModule(). - 2. Assert: referencingScriptOrModule is a Script Record or Module Record (i.e. is not null). - 3. Let argRef be the result of evaluating AssignmentExpression. - 4. Let specifier be ? GetValue(argRef). - 5. Let promiseCapability be ! NewPromiseCapability(%Promise%). - 6. Let specifierString be ToString(specifier). - 7. IfAbruptRejectPromise(specifierString, promiseCapability). - 8. Perform ! HostImportModuleDynamically(referencingScriptOrModule, specifierString, promiseCapability). - 9. Return promiseCapability.[[Promise]]. - ----*/ - -{ - import(''); -};