From 77c18d29c565e68a0d487e357765acb5ec776cc6 Mon Sep 17 00:00:00 2001 From: Outsider Date: Thu, 11 Aug 2022 02:37:13 +0900 Subject: [PATCH] chore: use standard 'Promise.allSettled' instead of polyfill (#4905) Signed-off-by: Outsider --- lib/nodejs/parallel-buffered-runner.js | 3 +-- package-lock.json | 11 ----------- package.json | 1 - 3 files changed, 1 insertion(+), 14 deletions(-) diff --git a/lib/nodejs/parallel-buffered-runner.js b/lib/nodejs/parallel-buffered-runner.js index 3f882ba227..6052efc0d1 100644 --- a/lib/nodejs/parallel-buffered-runner.js +++ b/lib/nodejs/parallel-buffered-runner.js @@ -6,7 +6,6 @@ 'use strict'; -const allSettled = require('@ungap/promise-all-settled').bind(Promise); const Runner = require('../runner'); const {EVENT_RUN_BEGIN, EVENT_RUN_END} = Runner.constants; const debug = require('debug')('mocha:parallel:parallel-buffered-runner'); @@ -322,7 +321,7 @@ class ParallelBufferedRunner extends Runner { delete options[opt]; }); - const results = await allSettled( + const results = await Promise.allSettled( files.map(this._createFileRunner(pool, options)) ); diff --git a/package-lock.json b/package-lock.json index d144e6a2d7..b2acc6f551 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,6 @@ "version": "10.0.0", "license": "MIT", "dependencies": { - "@ungap/promise-all-settled": "1.1.2", "ansi-colors": "4.1.1", "browser-stdout": "1.3.1", "chokidar": "3.5.3", @@ -1577,11 +1576,6 @@ "@types/node": "*" } }, - "node_modules/@ungap/promise-all-settled": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@ungap/promise-all-settled/-/promise-all-settled-1.1.2.tgz", - "integrity": "sha512-sL/cEvJWAnClXw0wHk85/2L0G6Sj8UB0Ctc1TEMbKSsmpRosqhwj9gWgFRZSrBr2f9tiXISwNhCPmlfqUqyb9Q==" - }, "node_modules/@wdio/config": { "version": "6.12.1", "resolved": "https://registry.npmjs.org/@wdio/config/-/config-6.12.1.tgz", @@ -25665,11 +25659,6 @@ "@types/node": "*" } }, - "@ungap/promise-all-settled": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@ungap/promise-all-settled/-/promise-all-settled-1.1.2.tgz", - "integrity": "sha512-sL/cEvJWAnClXw0wHk85/2L0G6Sj8UB0Ctc1TEMbKSsmpRosqhwj9gWgFRZSrBr2f9tiXISwNhCPmlfqUqyb9Q==" - }, "@wdio/config": { "version": "6.12.1", "resolved": "https://registry.npmjs.org/@wdio/config/-/config-6.12.1.tgz", diff --git a/package.json b/package.json index aba2b8f181..22eeff7f81 100644 --- a/package.json +++ b/package.json @@ -54,7 +54,6 @@ "test:smoke": "node ./bin/mocha --no-config test/smoke/smoke.spec.js" }, "dependencies": { - "@ungap/promise-all-settled": "1.1.2", "ansi-colors": "4.1.1", "browser-stdout": "1.3.1", "chokidar": "3.5.3",