/third_party/node/test/parallel/ |
H A D | test-assert-async.js | 6 const promises = []; 44 promises.push(assert.rejects(rejectingFn, errObj)); 45 promises.push(assert.rejects(rejectingFn(), errObj)); 53 promises.push(assert.rejects(validRejectingThenable, { code: 'FAIL' })); 57 promises.push(assert.rejects( 63 promises.push(assert.rejects( 72 promises.push(assert.rejects( 100 promises.push(assert.rejects(promise, common.mustCall(handler))); 103 promises.push(assert.rejects(promise, { 112 promises [all...] |
H A D | test-fs-opendir.js | 123 const dir = await fs.promises.opendir(testDir); 145 for await (const dirent of await fs.promises.opendir(testDir)) { 159 const dir = await fs.promises.opendir(testDir); 169 const dir = await fs.promises.opendir(testDir); 181 const dir = await fs.promises.opendir(testDir); 221 const dir = await fs.promises.opendir(testDir); 228 const dir = await fs.promises.opendir(testDir); 236 const dir = await fs.promises.opendir(testDir); 255 const dir = await fs.promises.opendir(testDir); 267 const dir = await fs.promises [all...] |
H A D | test-stream-map.js | 9 const { setTimeout } = require('timers/promises'); 200 const promises = createDependentPromises(4); 204 const [promise, resolve] = promises[item]; 223 const promises = createDependentPromises(20); 251 const [promise, resolve] = promises[item]; 271 const promises = createDependentPromises(20); 299 const [promise, resolve] = promises[item]; 318 const promises = createDependentPromises(3); 325 await promises[item][0]; 332 for (const [_, resolve] of promises) { [all...] |
H A D | test-dns-set-default-order.js | 10 // `dns.promises.setDefaultResultOrder()` works as expected. 20 const dnsPromises = dns.promises; 35 assert.throws(() => dns.promises.setDefaultResultOrder('my_order'), { 41 assert.throws(() => dns.promises.setDefaultResultOrder(4), { 74 dns.promises.setDefaultResultOrder('verbatim'); 84 dns.promises.setDefaultResultOrder('ipv4first');
|
H A D | test-fs-access.js | 77 fs.promises.access(__filename) 83 fs.promises.access(__filename, fs.R_OK) 89 fs.promises.access(readOnlyFile, fs.R_OK) 100 fs.promises.access(doesNotExist) 116 fs.promises.access(readOnlyFile, fs.W_OK) 132 fs.promises.access(100, fs.F_OK)
|
H A D | test-fs-rm.js | 306 await assert.rejects(fs.promises.rm(dir), { syscall: 'rm' }); 307 await assert.rejects(fs.promises.rm(dir, common.mustNotMutateObjectDeep({ recursive: false })), { 312 await fs.promises.rm(dir, common.mustNotMutateObjectDeep({ recursive: true })); 316 await assert.rejects(fs.promises.rm(dir), { syscall: 'lstat' }); 319 await assert.rejects(fs.promises.rm( 329 await fs.promises.rm(path.join(tmpdir.path, 'noexist.txt'), common.mustNotMutateObjectDeep({ force: true })); 332 const filePath = path.join(tmpdir.path, 'rm-promises-file.txt'); 336 await fs.promises.rm(filePath, common.mustNotMutateObjectDeep({ recursive: true })); 348 await fs.promises.rm(validLink); 359 await fs.promises [all...] |
H A D | test-fs-rmdir-recursive.js | 144 await assert.rejects(fs.promises.rmdir(dir), { syscall: 'rmdir' }); 145 await assert.rejects(fs.promises.rmdir(dir, { recursive: false }), { 150 await fs.promises.rmdir(dir, { recursive: true }); 153 await assert.rejects(fs.promises.rmdir(dir, { recursive: true }), 157 await assert.rejects(fs.promises.rmdir(dir), { syscall: 'rmdir' });
|
H A D | test-dns-perf_hooks.js | 27 dns.promises.lookup('localhost').then(inc).catch(() => {}); 28 dns.promises.lookupService('127.0.0.1', 80).then(inc).catch(() => {}); 29 dns.promises.resolveAny('localhost').then(inc).catch(() => {});
|
H A D | test-webcrypto-derivebits-hkdf.js | 159 const promises = []; 168 promises.push( 179 promises.push( 189 promises.push( 200 promises.push( 212 await Promise.all(promises);
|
/third_party/node/lib/internal/per_context/ |
H A D | primordials.js | 482 const arrayToSafePromiseIterable = (promises, mapFn) => 485 promises, 493 * @param {Array<T | PromiseLike<T>>} promises 497 primordials.SafePromiseAll = (promises, mapFn) => 501 SafePromise.all(arrayToSafePromiseIterable(promises, mapFn)).then(a, b), 509 * @param {ArrayLike<T | PromiseLike<T>>} promises 513 primordials.SafePromiseAllReturnArrayLike = (promises, mapFn) => 515 const { length } = promises; 523 const promise = mapFn != null ? mapFn(promises[i], i) : promises[ [all...] |
/third_party/node/benchmark/test_runner/ |
H A D | global-concurrent-tests.js | 14 const promises = new Array(n); 22 promises[i] = it(`${i}`, () => { 31 promises[i] = it(`${i}`, async () => { 38 await Promise.all(promises);
|
H A D | global-sequential-tests.js | 18 const promises = new Array(n); 38 await Promise.all(promises);
|
/third_party/node/lib/ |
H A D | dns.js | 103 let promises = null; // Lazy loaded 299 if (promises !== null) 300 bindDefaultResolver(promises, promises.Resolver.prototype); 347 promises: { 352 if (promises === null) { 353 promises = require('internal/dns/promises'); 355 return promises;
|
H A D | stream.js | 51 const promises = require('stream/promises'); 112 ObjectDefineProperty(Stream, 'promises', { 117 return promises; 125 return promises.pipeline; 133 return promises.finished;
|
/third_party/node/test/fixtures/wpt/streams/transform-streams/ |
H A D | lipfuzz.any.js | 142 const promises = []; 144 promises.push(writer.write(inputChunk)); 146 promises.push(writer.close()); 160 promises.push(readerChain); 161 return Promise.all(promises);
|
/third_party/node/deps/npm/node_modules/@npmcli/arborist/lib/arborist/ |
H A D | rebuild.js | 178 const promises = [] 180 promises.push(this.#addToBuildSet(node, set)) 188 leave: node => promises.push(this.#addToBuildSet(node, set)), 195 await promiseAllRejectLate(promises) 371 const promises = [] 376 promises.push(this.#createBinLinks(node)) 379 await promiseAllRejectLate(promises)
|
/third_party/typescript/tests/baselines/reference/ |
H A D | variableDeclaratorResolvedDuringContextualTyping.js | 23 static join(promises: { [name: string]: Promise; }): Promise; 24 static join(promises: Promise[]): Promise; 25 static any(promises: Promise[]): Promise; 50 public static join<ValueType>(promises: TPromise<ValueType>[]): TPromise<ValueType[]>; 51 public static any<ValueType>(promises: TPromise<ValueType>[]): TPromise<ValueType>;
|
/third_party/node/test/pummel/ |
H A D | test-webcrypto-derivebits-pbkdf2.js | 365 const promises = []; 373 promises.push( 382 promises.push( 391 promises.push( 401 promises.push( 408 await Promise.all(promises);
|
/third_party/node/test/fixtures/wpt/WebCryptoAPI/derive_bits_keys/ |
H A D | ecdh_bits.js | 195 var promises = []; 205 promises.push(operation); 216 promises.push(operation); 227 promises.push(operation); 236 promises.push(operation); 239 return Promise.all(promises)
|
H A D | ecdh_keys.js | 164 var promises = []; 174 promises.push(operation); 185 promises.push(operation); 196 promises.push(operation); 205 promises.push(operation); 208 return Promise.all(promises)
|
H A D | hkdf.js | 241 var promises = []; 255 promises.push(promise); 263 promises.push(promise); 271 promises.push(promise); 280 promises.push(promise); 283 return Promise.all(promises).then(function() {
|
H A D | cfrg_curves_bits.js | 188 var promises = []; 198 promises.push(operation); 209 promises.push(operation); 220 promises.push(operation); 223 return Promise.all(promises)
|
H A D | cfrg_curves_keys.js | 172 var promises = []; 182 promises.push(operation); 193 promises.push(operation); 204 promises.push(operation); 207 return Promise.all(promises)
|
H A D | pbkdf2.js | 238 var promises = []; 252 promises.push(promise); 260 promises.push(promise); 268 promises.push(promise); 277 promises.push(promise); 280 return Promise.all(promises).then(function() {
|
/third_party/node/test/fixtures/snapshot/ |
H A D | dns-resolve.js | 30 dns.promises.resolve4(host).then(onResolve, onError); 44 dns.promises.reverse(ip).then(onReverse, onError);
|