Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(24)

Unified Diff: test/mjsunit/wasm/memory-instance-validation.js

Issue 2591753002: [wasm] Implement correct 2-level namespace for imports. (Closed)
Patch Set: Fix debug tests Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/mjsunit/wasm/js-api.js ('k') | test/mjsunit/wasm/receiver.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/wasm/memory-instance-validation.js
diff --git a/test/mjsunit/wasm/memory-instance-validation.js b/test/mjsunit/wasm/memory-instance-validation.js
index 3457ff7c89985df6640fc5e03605528a52a6187e..e0220e6ee9389dcb074850b3759bf129f35765a8 100644
--- a/test/mjsunit/wasm/memory-instance-validation.js
+++ b/test/mjsunit/wasm/memory-instance-validation.js
@@ -13,7 +13,7 @@ load("test/mjsunit/wasm/wasm-module-builder.js");
print("ValidateSharedInstanceMemory");
let memory = new WebAssembly.Memory({initial: 5, maximum: 100});
var builder = new WasmModuleBuilder();
- builder.addImportedMemory("imported_mem");
+ builder.addImportedMemory("mod", "imported_mem");
builder.addFunction("mem_size", kSig_i_v)
.addBody([kExprMemorySize, kMemoryZero])
.exportFunc();
@@ -22,7 +22,7 @@ load("test/mjsunit/wasm/wasm-module-builder.js");
.exportFunc();
var instances = [];
for (var i = 0; i < 5; i++) {
- instances.push(builder.instantiate({imported_mem: memory}));
+ instances.push(builder.instantiate({mod: {imported_mem: memory}}));
}
function grow_instance_0(pages) { return instances[0].exports.grow(pages); }
function grow_instance_1(pages) { return instances[1].exports.grow(pages); }
@@ -82,7 +82,7 @@ load("test/mjsunit/wasm/wasm-module-builder.js");
assertEquals(28, instances[3].exports.mem_size());
// Instantiate a new instance and verify that it can be grown correctly.
- instances.push(builder.instantiate({imported_mem: memory}));
+ instances.push(builder.instantiate({mod: {imported_mem: memory}}));
function grow_instance_5(pages) { return instances[5].exports.grow(pages); }
// i[2] - i[3] - i[5]
« no previous file with comments | « test/mjsunit/wasm/js-api.js ('k') | test/mjsunit/wasm/receiver.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698