Skip to content

Commit

Permalink
fix: fix test ts build
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-yarmosh committed Nov 3, 2023
1 parent fabf341 commit c75b9fb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion test/tests/unit/ws/fetch-sockets.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@ import * as sinon from 'sinon';
import * as td from 'testdouble';
import { expect } from 'chai';

import type { LRUOptions } from '../../../../src/lib/ws/helper/throttle.js';
import type { RemoteProbeSocket } from '../../../../src/lib/ws/server.js';

const fetchRawSockets = sinon.stub().resolves([]);
const getAdoptedIpToProbe = sinon.stub();

describe('fetchSockets', () => {
let fetchSockets;
let fetchSockets: (options?: LRUOptions) => Promise<RemoteProbeSocket[]>;

before(async () => {
await td.replaceEsm('../../../../src/lib/ws/server.ts', { fetchRawSockets });
Expand Down
2 changes: 1 addition & 1 deletion test/tests/unit/ws/reconnect-probes.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const fetchSockets = sinon.stub().resolves([{ disconnect }, { disconnect }]);

describe('reconnectProbes', () => {
let sandbox: sinon.SinonSandbox;
let reconnectProbes;
let reconnectProbes: () => void;

before(async () => {
await td.replaceEsm('../../../../src/lib/ws/fetch-sockets.ts', {
Expand Down

0 comments on commit c75b9fb

Please sign in to comment.