| Index: third_party/WebKit/LayoutTests/fast/wasm/wasm-limits-tests.js
|
| diff --git a/third_party/WebKit/LayoutTests/fast/wasm/wasm-limits-tests.js b/third_party/WebKit/LayoutTests/fast/wasm/wasm-limits-tests.js
|
| index 9d1b67850553fda2567c63b28c8b94e3aa3e36c1..f246109a016b14fc83215a00cb9f934e9447579f 100644
|
| --- a/third_party/WebKit/LayoutTests/fast/wasm/wasm-limits-tests.js
|
| +++ b/third_party/WebKit/LayoutTests/fast/wasm/wasm-limits-tests.js
|
| @@ -93,3 +93,26 @@ function TestPromiseCompileAsyncInstantiateFromModule() {
|
| },
|
| assert_unreached);
|
| }
|
| +
|
| +
|
| +function TestCompileFromPromise() {
|
| + return Promise.resolve(createTestBuffers(limit).large)
|
| + .then(WebAssembly.compile)
|
| + .then(m => assert_true(m instanceof WebAssembly.Module))
|
| +}
|
| +
|
| +function TestInstantiateFromPromise() {
|
| + return Promise.resolve(createTestBuffers(limit).large)
|
| + .then(WebAssembly.instantiate)
|
| + .then(pair => {
|
| + assert_true(pair.module instanceof WebAssembly.Module);
|
| + assert_true(pair.instance instanceof WebAssembly.Instance);
|
| + });
|
| +}
|
| +
|
| +function TestInstantiateFromPromiseChain() {
|
| + return Promise.resolve(createTestBuffers(limit).large)
|
| + .then(WebAssembly.compile)
|
| + .then(WebAssembly.instantiate)
|
| + .then(i => assert_true(i instanceof WebAssembly.Instance))
|
| +}
|
|
|