1
+ /* eslint-disable @typescript-eslint/no-empty-function */
2
+
1
3
// utils
2
4
jest . mock ( '../../src/utils' , ( ) => ( {
3
5
...jest . requireActual ( '../../src/utils' ) ,
@@ -113,7 +115,7 @@ describe('default option', () => {
113
115
describe ( 'context missing option' , ( ) => {
114
116
test ( 'not specified missing handler' , ( ) => {
115
117
const mockWarn = warn as jest . MockedFunction < typeof warn >
116
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
118
+ mockWarn . mockImplementation ( ( ) => { } )
117
119
118
120
const ctx = context ( {
119
121
locale : 'en' ,
@@ -130,7 +132,7 @@ describe('context missing option', () => {
130
132
131
133
test ( 'specified missing handler' , ( ) => {
132
134
const mockWarn = warn as jest . MockedFunction < typeof warn >
133
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
135
+ mockWarn . mockImplementation ( ( ) => { } )
134
136
135
137
const ctx = context ( {
136
138
locale : 'en' ,
@@ -151,7 +153,7 @@ describe('context missing option', () => {
151
153
describe ( 'context missingWarn option' , ( ) => {
152
154
test ( 'false' , ( ) => {
153
155
const mockWarn = warn as jest . MockedFunction < typeof warn >
154
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
156
+ mockWarn . mockImplementation ( ( ) => { } )
155
157
156
158
const ctx = context ( {
157
159
locale : 'en' ,
@@ -168,7 +170,7 @@ describe('context missingWarn option', () => {
168
170
169
171
test ( 'regex' , ( ) => {
170
172
const mockWarn = warn as jest . MockedFunction < typeof warn >
171
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
173
+ mockWarn . mockImplementation ( ( ) => { } )
172
174
173
175
const ctx = context ( {
174
176
locale : 'en' ,
@@ -189,7 +191,7 @@ describe('context missingWarn option', () => {
189
191
190
192
test ( 'missingWarn option' , ( ) => {
191
193
const mockWarn = warn as jest . MockedFunction < typeof warn >
192
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
194
+ mockWarn . mockImplementation ( ( ) => { } )
193
195
194
196
const ctx = context ( {
195
197
locale : 'en' ,
@@ -207,7 +209,7 @@ describe('context missingWarn option', () => {
207
209
describe ( 'context fallbackWarn option' , ( ) => {
208
210
test ( 'not specify fallbackLocale' , ( ) => {
209
211
const mockWarn = warn as jest . MockedFunction < typeof warn >
210
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
212
+ mockWarn . mockImplementation ( ( ) => { } )
211
213
212
214
const ctx = context ( {
213
215
locale : 'en' ,
@@ -223,7 +225,7 @@ describe('context fallbackWarn option', () => {
223
225
224
226
test ( 'specify fallbackLocale' , ( ) => {
225
227
const mockWarn = warn as jest . MockedFunction < typeof warn >
226
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
228
+ mockWarn . mockImplementation ( ( ) => { } )
227
229
228
230
const ctx = context ( {
229
231
locale : 'en' ,
@@ -246,7 +248,7 @@ describe('context fallbackWarn option', () => {
246
248
247
249
test ( 'not found fallback message' , ( ) => {
248
250
const mockWarn = warn as jest . MockedFunction < typeof warn >
249
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
251
+ mockWarn . mockImplementation ( ( ) => { } )
250
252
251
253
const ctx = context ( {
252
254
locale : 'en' ,
@@ -270,7 +272,7 @@ describe('context fallbackWarn option', () => {
270
272
271
273
test ( 'context option: false' , ( ) => {
272
274
const mockWarn = warn as jest . MockedFunction < typeof warn >
273
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
275
+ mockWarn . mockImplementation ( ( ) => { } )
274
276
275
277
const ctx = context ( {
276
278
locale : 'en' ,
@@ -289,7 +291,7 @@ describe('context fallbackWarn option', () => {
289
291
290
292
test ( 'context option: regex' , ( ) => {
291
293
const mockWarn = warn as jest . MockedFunction < typeof warn >
292
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
294
+ mockWarn . mockImplementation ( ( ) => { } )
293
295
294
296
const ctx = context ( {
295
297
locale : 'en' ,
@@ -308,7 +310,7 @@ describe('context fallbackWarn option', () => {
308
310
309
311
test ( 'specify fallbackWarn option to translate function' , ( ) => {
310
312
const mockWarn = warn as jest . MockedFunction < typeof warn >
311
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
313
+ mockWarn . mockImplementation ( ( ) => { } )
312
314
313
315
const ctx = context ( {
314
316
locale : 'en' ,
@@ -331,7 +333,7 @@ describe('context fallbackWarn option', () => {
331
333
describe ( 'context fallbackFormat option' , ( ) => {
332
334
test ( 'specify true' , ( ) => {
333
335
const mockWarn = warn as jest . MockedFunction < typeof warn >
334
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
336
+ mockWarn . mockImplementation ( ( ) => { } )
335
337
336
338
const ctx = context ( {
337
339
locale : 'en' ,
@@ -367,7 +369,7 @@ describe('context fallbackFormat option', () => {
367
369
368
370
test ( 'overrided with default option' , ( ) => {
369
371
const mockWarn = warn as jest . MockedFunction < typeof warn >
370
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
372
+ mockWarn . mockImplementation ( ( ) => { } )
371
373
372
374
const ctx = context ( {
373
375
locale : 'en' ,
@@ -403,7 +405,7 @@ describe('context fallbackFormat option', () => {
403
405
404
406
test ( 'fallbackLocales is nothing' , ( ) => {
405
407
const mockWarn = warn as jest . MockedFunction < typeof warn >
406
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
408
+ mockWarn . mockImplementation ( ( ) => { } )
407
409
408
410
const ctx = context ( {
409
411
locale : 'en' ,
@@ -456,7 +458,7 @@ describe('context unresolving option', () => {
456
458
457
459
test ( 'fallbackFormat is true' , ( ) => {
458
460
const mockWarn = warn as jest . MockedFunction < typeof warn >
459
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
461
+ mockWarn . mockImplementation ( ( ) => { } )
460
462
461
463
const ctx = context ( {
462
464
locale : 'en' ,
@@ -530,7 +532,7 @@ describe('context postTranslation option', () => {
530
532
describe ( 'warnHtmlMessage' , ( ) => {
531
533
test ( 'default' , ( ) => {
532
534
const mockWarn = warn as jest . MockedFunction < typeof warn >
533
- mockWarn . mockImplementation ( ( ) => { } ) // eslint-disable-line @typescript-eslint/no-empty-function
535
+ mockWarn . mockImplementation ( ( ) => { } )
534
536
535
537
const ctx = context ( {
536
538
locale : 'en' ,
@@ -571,3 +573,5 @@ describe('edge cases', () => {
571
573
expect ( translate ( ctx , 'side.left' ) ) . toEqual ( 'Left' )
572
574
} )
573
575
} )
576
+
577
+ /* eslint-enable @typescript-eslint/no-empty-function */
0 commit comments