From: Jérôme Benoit Date: Sat, 2 Nov 2024 20:02:44 +0000 (+0100) Subject: chore: cleanup `@std/expect` imports X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=a274b5a5cf27f66d7a7501b041cdd27a8152ccce;p=poolifier.git chore: cleanup `@std/expect` imports Signed-off-by: Jérôme Benoit --- diff --git a/package.json b/package.json index 826645da..f32c3f53 100644 --- a/package.json +++ b/package.json @@ -111,6 +111,7 @@ "@eslint/js": "^9.14.0", "@rollup/plugin-terser": "^0.4.4", "@rollup/plugin-typescript": "^12.1.1", + "@std/expect": "npm:@jsr/std__expect@^1.0.7", "@types/node": "^22.8.6", "c8": "^10.1.2", "clean-publish": "^5.1.0", @@ -119,7 +120,6 @@ "eslint-define-config": "^2.1.0", "eslint-plugin-jsdoc": "^50.4.3", "eslint-plugin-perfectionist": "^3.9.1", - "expect": "npm:@jsr/std__expect@^1.0.7", "globals": "^15.11.0", "husky": "^9.1.6", "lint-staged": "^15.2.10", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f95308d0..478ab881 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -32,6 +32,9 @@ importers: '@rollup/plugin-typescript': specifier: ^12.1.1 version: 12.1.1(rollup@4.24.3)(tslib@2.8.0)(typescript@5.6.3) + '@std/expect': + specifier: npm:@jsr/std__expect@^1.0.7 + version: '@jsr/std__expect@1.0.7' '@types/node': specifier: ^22.8.6 version: 22.8.6 @@ -56,9 +59,6 @@ importers: eslint-plugin-perfectionist: specifier: ^3.9.1 version: 3.9.1(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) - expect: - specifier: npm:@jsr/std__expect@^1.0.7 - version: '@jsr/std__expect@1.0.7' globals: specifier: ^15.11.0 version: 15.11.0 diff --git a/tests/circular-buffer.test.mjs b/tests/circular-buffer.test.mjs index 751ece90..c1a1a4f5 100644 --- a/tests/circular-buffer.test.mjs +++ b/tests/circular-buffer.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { CircularBuffer, defaultBufferSize } from '../lib/circular-buffer.cjs' diff --git a/tests/pools/abstract-pool.test.mjs b/tests/pools/abstract-pool.test.mjs index d9d82f8a..91ae1d2e 100644 --- a/tests/pools/abstract-pool.test.mjs +++ b/tests/pools/abstract-pool.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' // eslint-disable-next-line n/no-unsupported-features/node-builtins import { createHook, executionAsyncId } from 'node:async_hooks' import { EventEmitterAsyncResource } from 'node:events' diff --git a/tests/pools/cluster/dynamic.test.mjs b/tests/pools/cluster/dynamic.test.mjs index e930c6d6..e1b386a4 100644 --- a/tests/pools/cluster/dynamic.test.mjs +++ b/tests/pools/cluster/dynamic.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { DynamicClusterPool, diff --git a/tests/pools/cluster/fixed.test.mjs b/tests/pools/cluster/fixed.test.mjs index 4be196d6..e911a60c 100644 --- a/tests/pools/cluster/fixed.test.mjs +++ b/tests/pools/cluster/fixed.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import cluster from 'node:cluster' import { FixedClusterPool, PoolEvents } from '../../../lib/index.cjs' diff --git a/tests/pools/selection-strategies/selection-strategies-utils.test.mjs b/tests/pools/selection-strategies/selection-strategies-utils.test.mjs index 2968f894..13e7694f 100644 --- a/tests/pools/selection-strategies/selection-strategies-utils.test.mjs +++ b/tests/pools/selection-strategies/selection-strategies-utils.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { FixedClusterPool, FixedThreadPool } from '../../../lib/index.cjs' import { diff --git a/tests/pools/selection-strategies/selection-strategies.test.mjs b/tests/pools/selection-strategies/selection-strategies.test.mjs index 6a1aab6b..949cb3d9 100644 --- a/tests/pools/selection-strategies/selection-strategies.test.mjs +++ b/tests/pools/selection-strategies/selection-strategies.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { randomInt } from 'node:crypto' import { CircularBuffer } from '../../../lib/circular-buffer.cjs' diff --git a/tests/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.test.mjs b/tests/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.test.mjs index 18a67bd7..7bfeb4b0 100644 --- a/tests/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.test.mjs +++ b/tests/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { randomInt } from 'node:crypto' import { FixedThreadPool } from '../../../lib/index.cjs' diff --git a/tests/pools/selection-strategies/worker-choice-strategies-context.test.mjs b/tests/pools/selection-strategies/worker-choice-strategies-context.test.mjs index c653d9f5..0d6a77ed 100644 --- a/tests/pools/selection-strategies/worker-choice-strategies-context.test.mjs +++ b/tests/pools/selection-strategies/worker-choice-strategies-context.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { createStubInstance, restore, stub } from 'sinon' import { diff --git a/tests/pools/thread/dynamic.test.mjs b/tests/pools/thread/dynamic.test.mjs index 6188abe2..d78ebbd9 100644 --- a/tests/pools/thread/dynamic.test.mjs +++ b/tests/pools/thread/dynamic.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { DynamicThreadPool, diff --git a/tests/pools/thread/fixed.test.mjs b/tests/pools/thread/fixed.test.mjs index 734ca002..dd01556f 100644 --- a/tests/pools/thread/fixed.test.mjs +++ b/tests/pools/thread/fixed.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { FixedThreadPool, PoolEvents } from '../../../lib/index.cjs' import { DEFAULT_TASK_NAME } from '../../../lib/utils.cjs' diff --git a/tests/pools/utils.test.mjs b/tests/pools/utils.test.mjs index 36862a2a..ef6dd318 100644 --- a/tests/pools/utils.test.mjs +++ b/tests/pools/utils.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import cluster, { Worker as ClusterWorker } from 'node:cluster' import { Worker as ThreadWorker } from 'node:worker_threads' diff --git a/tests/pools/worker-node.test.mjs b/tests/pools/worker-node.test.mjs index 42eb4434..d0f56367 100644 --- a/tests/pools/worker-node.test.mjs +++ b/tests/pools/worker-node.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { Worker as ClusterWorker } from 'node:cluster' import { MessageChannel, Worker as ThreadWorker } from 'node:worker_threads' diff --git a/tests/queues/fixed-priority-queue.test.mjs b/tests/queues/fixed-priority-queue.test.mjs index 36474b0b..d91ea712 100644 --- a/tests/queues/fixed-priority-queue.test.mjs +++ b/tests/queues/fixed-priority-queue.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { FixedPriorityQueue } from '../../lib/queues/fixed-priority-queue.cjs' import { defaultQueueSize } from '../../lib/queues/queue-types.cjs' diff --git a/tests/queues/fixed-queue.test.mjs b/tests/queues/fixed-queue.test.mjs index 7fa7ac02..7b1053ad 100644 --- a/tests/queues/fixed-queue.test.mjs +++ b/tests/queues/fixed-queue.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { FixedQueue } from '../../lib/queues/fixed-queue.cjs' import { defaultQueueSize } from '../../lib/queues/queue-types.cjs' diff --git a/tests/queues/priority-queue.test.mjs b/tests/queues/priority-queue.test.mjs index 52d18dbf..48a68732 100644 --- a/tests/queues/priority-queue.test.mjs +++ b/tests/queues/priority-queue.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { FixedPriorityQueue } from '../../lib/queues/fixed-priority-queue.cjs' import { FixedQueue } from '../../lib/queues/fixed-queue.cjs' diff --git a/tests/utils.test.mjs b/tests/utils.test.mjs index 4f84d818..2001ddcd 100644 --- a/tests/utils.test.mjs +++ b/tests/utils.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { randomInt } from 'node:crypto' import os from 'node:os' diff --git a/tests/worker/abstract-worker.test.mjs b/tests/worker/abstract-worker.test.mjs index 669f9b3f..68238dea 100644 --- a/tests/worker/abstract-worker.test.mjs +++ b/tests/worker/abstract-worker.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { restore, stub } from 'sinon' import { diff --git a/tests/worker/cluster-worker.test.mjs b/tests/worker/cluster-worker.test.mjs index a7de4671..eaf46d22 100644 --- a/tests/worker/cluster-worker.test.mjs +++ b/tests/worker/cluster-worker.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { restore, stub } from 'sinon' import { ClusterWorker } from '../../lib/index.cjs' diff --git a/tests/worker/thread-worker.test.mjs b/tests/worker/thread-worker.test.mjs index 269f4a7a..4d10cf62 100644 --- a/tests/worker/thread-worker.test.mjs +++ b/tests/worker/thread-worker.test.mjs @@ -1,4 +1,4 @@ -import { expect } from 'expect' +import { expect } from '@std/expect' import { restore, stub } from 'sinon' import { ThreadWorker } from '../../lib/index.cjs'