Skip to content

Commit a7d2714

Browse files
committed
Added files to eslint.config.ts
1 parent 3188a7c commit a7d2714

4 files changed

Lines changed: 15 additions & 20 deletions

File tree

eslint.config.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,15 @@ export default [
6363
rules: {
6464
'jest/no-disabled-tests': 'warn',
6565
'jest/no-focused-tests': 'error',
66+
'no-console': 'off',
67+
'@typescript-eslint/no-explicit-any': 'off',
68+
},
69+
},
70+
{
71+
files: ['src/utils/logger.ts'],
72+
rules: {
73+
'no-console': 'off',
74+
'@typescript-eslint/no-explicit-any': 'off',
6675
},
6776
},
6877
];

src/services/fluent-api.test.ts

Lines changed: 6 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
1-
/* eslint-disable @typescript-eslint/no-explicit-any */
2-
/* eslint-disable no-console */
3-
4-
// Move your logic inside a describe/it block
51
describe('Fluent API Integration', () => {
62
const TEST_CONFIG = {
73
baseUrl: 'https://dev.api.fluent.bible',
84
endpoint: '/languages',
95
};
106

117
it('demonstrates a successful connection to the Fluent API', async () => {
12-
console.log('🚀 Starting Fluent API Integration Test...');
8+
console.log('Starting Fluent API Integration Test...');
139

1410
try {
1511
const response = await fetch(
@@ -21,30 +17,25 @@ describe('Fluent API Integration', () => {
2117
);
2218

2319
if (response.status === 403) {
24-
console.log('✅ TEST SUCCESSFUL: Server reached (403 Forbidden)');
25-
// This satisfies Jest that the test passed
20+
console.log('TEST SUCCESSFUL: Server reached (403 Forbidden)');
2621
expect(response.status).toBe(403);
2722
return;
2823
}
2924

3025
if (response.ok) {
3126
const data = await response.json();
32-
console.log('TEST SUCCESSFUL: Data received!');
27+
console.log('TEST SUCCESSFUL: Data received!');
3328
console.log(
34-
'📦 Sample Data:',
29+
'Sample Data:',
3530
data?.[1]?.langName || 'No languages found',
3631
);
3732
expect(response.status).toBe(200);
3833
}
3934
} catch (error: any) {
40-
console.error('❌ TEST FAILED:', error.message);
41-
// Force the test to fail if the network is down
35+
console.error('TEST FAILED:', error.message);
4236
throw error;
4337
}
4438
});
4539
});
4640

47-
// Keep the export if you still want to call it from App.tsx
48-
export const runApiIntegrationTest = async () => {
49-
// You can move the logic above into a shared function if needed
50-
};
41+
export const runApiIntegrationTest = async () => {};

src/utils/logger.test.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
/* eslint-disable @typescript-eslint/no-explicit-any */
2-
31
import { logger, defaultTransport } from './logger';
42

53
describe('Logger', () => {

src/utils/logger.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
/* eslint-disable @typescript-eslint/no-explicit-any */
2-
/* eslint-disable no-console */
3-
41
export type LogLevel = 'debug' | 'info' | 'warn' | 'error';
52

63
export type Transport = (

0 commit comments

Comments
 (0)