(name, params, expected)
| 2 | |
| 3 | function runTests() { |
| 4 | let testCall = (name, params, expected) => { |
| 5 | let result = go._inst.exports[name].apply(null, params); |
| 6 | if (result !== expected) { |
| 7 | console.error(`${name}(...${params}): expected result ${expected}, got ${result}`); |
| 8 | } |
| 9 | } |
| 10 | |
| 11 | // These are the same tests as in TestWasmExport. |
| 12 | testCall('hello', [], undefined); |