| 1 |
const wasm = require('wasm-bindgen-test.js'); |
| 2 |
const assert = require('assert'); |
| 3 |
|
| 4 |
exports.call_throw_one = function() { |
| 5 |
try { |
| 6 |
wasm.throw_one(); |
| 7 |
} catch (e) { |
| 8 |
assert.strictEqual(e, 1); |
| 9 |
} |
| 10 |
}; |
| 11 |
|
| 12 |
exports.call_ok = function() { |
| 13 |
wasm.nothrow(); |
| 14 |
}; |