Tests enhancement (#172)
authorAlessandro Pio Ardizio <alessandroardizio94@gmail.com>
Wed, 17 Feb 2021 09:54:49 +0000 (10:54 +0100)
committerGitHub <noreply@github.com>
Wed, 17 Feb 2021 09:54:49 +0000 (10:54 +0100)
commit85a3f8a7b3087e7240c1d307ba6dd78c05883f83
tree77edcf28c756a41297c6682beaf834c554fad1a2
parent3832ad95c98b136ef703a29685fedebe4a5e3ba2
Tests enhancement (#172)

* Increase coverage and remove deprecated methods

* Add utility test function instead of use setTimeout to wait workers scale down

* Decrease a little bit the required nyc percentages

* Add a TestUtils class.

Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* More sleep usage.

Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* Run npm format.

Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* Remove deprecated methods and update changelog, increase require coverage

* Check coverage change

Co-authored-by: Jérôme Benoit <jerome.benoit@sap.com>
16 files changed:
.nycrc.json [new file with mode: 0644]
CHANGELOG.md
benchmarks/bench.js
package.json
src/pools/abstract-pool.ts
tests/pools/cluster/dynamic.test.js
tests/pools/cluster/fixed.test.js
tests/pools/thread/dynamic.test.js
tests/pools/thread/fixed.test.js
tests/test-utils.js [new file with mode: 0644]
tests/worker-files/cluster/echoWorker.js
tests/worker-files/cluster/longRunningWorkerHardBehavior.js [moved from tests/worker/cluster/longRunningWorkerHardBehavior.js with 100% similarity]
tests/worker-files/cluster/longRunningWorkerSoftBehavior.js [moved from tests/worker/cluster/longRunningWorkerSoftBehavior.js with 100% similarity]
tests/worker-files/thread/echoWorker.js
tests/worker-files/thread/longRunningWorkerHardBehavior.js [moved from tests/worker/thread/longRunningWorkerHardBehavior.js with 100% similarity]
tests/worker-files/thread/longRunningWorkerSoftBehavior.js [moved from tests/worker/thread/longRunningWorkerSoftBehavior.js with 100% similarity]