MCPcopy Index your code
hub / github.com/nodejs/node / assertIsPromise

Function assertIsPromise

test/parallel/test-primordials-promise.js:128–133  ·  view source on GitHub ↗
(promise)

Source from the content-addressed store, hash-verified

126}
127
128function assertIsPromise(promise) {
129 // Make sure the returned promise is a genuine %Promise% object and not a
130 // subclass instance.
131 assert.strictEqual(Object.getPrototypeOf(promise), Promise.prototype);
132 PromisePrototypeThen(promise, common.mustCall());
133}

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected