Skip to content

Commit 4cc9a6f

Browse files
committed
style: fix eslint errors
1 parent 48fdf59 commit 4cc9a6f

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

jest.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
/** @type {import('ts-jest').JestConfigWithTsJest} **/
2+
/* eslint-disable no-undef */
23
module.exports = {
34
preset: 'ts-jest',
45
testEnvironment: "node",

src/tests/MikrotikWireGuardClientManager.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,16 @@ describe('MikroTikWireGuardClientManager', () => {
1212

1313
beforeEach(() => {
1414
manager = new MikroTikWireGuardClientManager(mockSSHClient);
15-
jest.spyOn(manager, 'listClients'); // Ensure that listClients is mocked
15+
jest.spyOn(manager, 'listClients');
1616
});
1717

1818
it('should add a client successfully', async () => {
1919
const publicKey = 'testPublicKey';
2020
const comment = 'Test Comment';
2121
const mockIp = '192.168.1.2/24';
2222

23-
// Mock the methods
2423
(mockSSHClient.executeCommand as jest.Mock).mockResolvedValueOnce('output with public key');
24+
/* eslint-disable @typescript-eslint/no-explicit-any */
2525
(manager as any).getNextAvailableIp = jest.fn().mockResolvedValue(mockIp);
2626
(manager as any).getWireGuardInterfaceInfo = jest.fn().mockResolvedValue({ publicKey: 'routerPublicKey', listenPort: 51820 });
2727

0 commit comments

Comments
 (0)