blob: 94db1a436a387d08bb48fdfd3b1c1fc637348eee [file] [log] [blame]
import * as assert from '../assert.js';
import Builder from '../Builder.js';
(function EmptyModule() {
const builder = new Builder();
const bin = builder.WebAssembly().get();
const module = new WebAssembly.Module(bin);
assert.instanceof(module, WebAssembly.Module);
})();
(function ModuleWithImports() {
const builder = (new Builder())
.Type().End()
.Import()
.Function("foo", "bar", { params: [] })
.End();
const bin = builder.WebAssembly().get();
const module = new WebAssembly.Module(bin);
})();