Skip to content

Commit d27d2ab

Browse files
committed
BN-75 |Fix. lint errors
1 parent a8c8c90 commit d27d2ab

File tree

5 files changed

+319
-339
lines changed

5 files changed

+319
-339
lines changed

src/displayControls/diagnoses/__tests__/DiagnosesControl.integration.test.tsx

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import { NotificationProvider } from '@providers/NotificationProvider';
1010
import { I18nextProvider } from 'react-i18next';
1111
import i18n from '@/setupTests.i18n';
1212
import { axe, toHaveNoViolations } from 'jest-axe';
13+
import { DiagnosisCertainty } from '@/types/diagnosis';
1314

1415
// Extend Jest matchers for accessibility testing
1516
expect.extend(toHaveNoViolations);
@@ -100,23 +101,23 @@ describe('DiagnosesControl Integration', () => {
100101
{
101102
id: 'diagnosis-1',
102103
display: 'Type 2 Diabetes Mellitus',
103-
certainty: 'Confirmed' as any,
104+
certainty: 'Confirmed' as DiagnosisCertainty,
104105
recordedDate: '2025-01-15T10:30:00Z',
105106
formattedDate: 'Jan 15, 2025',
106107
recorder: 'Dr. Jane Smith',
107108
},
108109
{
109110
id: 'diagnosis-2',
110111
display: 'Hypertension',
111-
certainty: 'Provisional' as any,
112+
certainty: 'Provisional' as DiagnosisCertainty,
112113
recordedDate: '2025-01-15T10:35:00Z',
113114
formattedDate: 'Jan 15, 2025',
114115
recorder: 'Dr. Jane Smith',
115116
},
116117
{
117118
id: 'diagnosis-3',
118119
display: 'Asthma',
119-
certainty: 'Confirmed' as any,
120+
certainty: 'Confirmed' as DiagnosisCertainty,
120121
recordedDate: '2025-01-10T14:20:00Z',
121122
formattedDate: 'Jan 10, 2025',
122123
recorder: 'Dr. Robert Johnson',
@@ -175,7 +176,7 @@ describe('DiagnosesControl Integration', () => {
175176
{
176177
id: 'diagnosis-1',
177178
display: 'Type 2 Diabetes Mellitus',
178-
certainty: 'Confirmed' as any,
179+
certainty: 'Confirmed' as DiagnosisCertainty,
179180
recordedDate: '2025-01-15T10:30:00Z',
180181
formattedDate: 'Jan 15, 2025',
181182
recorder: 'Dr. Jane Smith',
@@ -189,7 +190,7 @@ describe('DiagnosesControl Integration', () => {
189190
{
190191
id: 'diagnosis-1',
191192
display: 'Type 2 Diabetes Mellitus',
192-
certainty: 'Confirmed' as any,
193+
certainty: 'Confirmed' as DiagnosisCertainty,
193194
recordedDate: '2025-01-15T10:30:00Z',
194195
formattedDate: 'Jan 15, 2025',
195196
recorder: 'Dr. Jane Smith',
@@ -297,7 +298,7 @@ describe('DiagnosesControl Integration', () => {
297298
const largeDiagnosList = Array.from({ length: 50 }, (_, index) => ({
298299
id: `diagnosis-${index}`,
299300
display: `Diagnosis ${index}`,
300-
certainty: index % 2 === 0 ? 'Confirmed' as any : 'Provisional' as any,
301+
certainty: (index % 2 === 0 ? 'Confirmed' : 'Provisional') as DiagnosisCertainty,
301302
recordedDate: `2025-01-${String(index % 30 + 1).padStart(2, '0')}T10:30:00Z`,
302303
formattedDate: `Jan ${index % 30 + 1}, 2025`,
303304
recorder: `Dr. Provider ${index % 5}`,
@@ -350,7 +351,7 @@ describe('DiagnosesControl Integration', () => {
350351
{
351352
id: 'diagnosis-1',
352353
display: 'Type 2 Diabetes Mellitus',
353-
certainty: 'Confirmed' as any,
354+
certainty: 'Confirmed' as DiagnosisCertainty,
354355
recordedDate: '2025-01-15T10:30:00Z',
355356
formattedDate: 'Jan 15, 2025',
356357
recorder: 'Dr. Jane Smith',
@@ -364,7 +365,7 @@ describe('DiagnosesControl Integration', () => {
364365
{
365366
id: 'diagnosis-1',
366367
display: 'Type 2 Diabetes Mellitus',
367-
certainty: 'Confirmed' as any,
368+
certainty: 'Confirmed' as DiagnosisCertainty,
368369
recordedDate: '2025-01-15T10:30:00Z',
369370
formattedDate: 'Jan 15, 2025',
370371
recorder: 'Dr. Jane Smith',
@@ -395,7 +396,7 @@ describe('DiagnosesControl Integration', () => {
395396
{
396397
id: 'diagnosis-1',
397398
display: 'Type 2 Diabetes Mellitus',
398-
certainty: 'Confirmed' as any,
399+
certainty: 'Confirmed' as DiagnosisCertainty,
399400
recordedDate: '2025-01-15T10:30:00Z',
400401
formattedDate: 'Jan 15, 2025',
401402
recorder: 'Dr. Jane Smith',
@@ -457,15 +458,15 @@ describe('DiagnosesControl Integration', () => {
457458
{
458459
id: 'diagnosis-1',
459460
display: 'Type 2 Diabetes Mellitus',
460-
certainty: 'Confirmed' as any,
461+
certainty: 'Confirmed' as DiagnosisCertainty,
461462
recordedDate: '2025-01-15T10:30:00Z',
462463
formattedDate: 'Jan 15, 2025',
463464
recorder: 'Dr. Jane Smith',
464465
},
465466
{
466467
id: 'diagnosis-2',
467468
display: 'Hypertension',
468-
certainty: 'Provisional' as any,
469+
certainty: 'Provisional' as DiagnosisCertainty,
469470
recordedDate: '2025-01-15T10:35:00Z',
470471
formattedDate: 'Jan 15, 2025',
471472
recorder: 'Dr. Jane Smith',
@@ -479,15 +480,15 @@ describe('DiagnosesControl Integration', () => {
479480
{
480481
id: 'diagnosis-1',
481482
display: 'Type 2 Diabetes Mellitus',
482-
certainty: 'Confirmed' as any,
483+
certainty: 'Confirmed' as DiagnosisCertainty,
483484
recordedDate: '2025-01-15T10:30:00Z',
484485
formattedDate: 'Jan 15, 2025',
485486
recorder: 'Dr. Jane Smith',
486487
},
487488
{
488489
id: 'diagnosis-2',
489490
display: 'Hypertension',
490-
certainty: 'Provisional' as any,
491+
certainty: 'Provisional' as DiagnosisCertainty,
491492
recordedDate: '2025-01-15T10:35:00Z',
492493
formattedDate: 'Jan 15, 2025',
493494
recorder: 'Dr. Jane Smith',

0 commit comments

Comments
 (0)