mirror of https://github.com/lukechilds/node.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
461 B
13 lines
461 B
8 years ago
|
'use strict';
|
||
|
|
||
|
const common = require('../../common');
|
||
|
const assert = require('assert');
|
||
|
|
||
|
// addon is referenced through the eval expression in testFile
|
||
|
// eslint-disable-next-line no-unused-vars
|
||
|
const addon = require(`./build/${common.buildType}/test_general`);
|
||
|
|
||
|
assert.strictEqual(addon.testNapiRun('(41.92 + 0.08);'), 42,
|
||
|
'napi_run_script() works correctly');
|
||
|
assert.throws(() => addon.testNapiRun({ abc: 'def' }), /string was expected/);
|