MCPcopy Create free account
hub / github.com/nodejs/node-addon-api / testCastedEqual

Function testCastedEqual

test/object_reference.js:52–61  ·  view source on GitHub ↗
(testToCompare)

Source from the content-addressed store, hash-verified

50 binding.objectreference.setWithTempString('testValue');
51
52 function testCastedEqual (testToCompare) {
53 const compareTest = ['hello', 'world', '!'];
54 if (testToCompare instanceof Array) {
55 assert.deepEqual(compareTest, testToCompare);
56 } else if (testToCompare instanceof String) {
57 assert.deepEqual('No Referenced Value', testToCompare);
58 } else {
59 assert.fail();
60 }
61 }
62
63 return testUtil.runGCTests([
64 'Weak Casted Array',

Callers 1

testFunction · 0.85

Calls

no outgoing calls

Tested by 1

testFunction · 0.68