@@ -16,7 +16,7 @@ import {
16
16
getInputValue ,
17
17
render ,
18
18
wait ,
19
- simulateNativeKeyInput
19
+ simulateNativeKeyInput ,
20
20
} from '../test_util' ;
21
21
import PatternFormat , { usePatternFormat } from '../../src/pattern_format' ;
22
22
import NumberFormatBase from '../../src/number_format_base' ;
@@ -287,19 +287,19 @@ describe('NumberFormat as input', () => {
287
287
simulateKeyInput ( wrapper . find ( 'input' ) , '8' , 0 , format . length ) ;
288
288
expect ( getInputValue ( wrapper ) ) . toEqual ( '+1 (8__) ___ _ __ US' ) ;
289
289
} ) ;
290
-
290
+
291
291
it ( 'should give proper value when format character has number #652' , ( ) => {
292
292
//https://github.com/s-yadav/react-number-format/issues/652#issuecomment-1278200770
293
293
const spy = jasmine . createSpy ( ) ;
294
- const wrapper = mount ( < PatternFormat format = "13###" mask = "_" onValueChange = { spy } /> ) ;
294
+ const wrapper = mount ( < PatternFormat format = "13###" mask = "_" onValueChange = { spy } /> ) ;
295
295
simulateKeyInput ( wrapper . find ( 'input' ) , '3' , 0 ) ;
296
296
simulateKeyInput ( wrapper . find ( 'input' ) , '4' , 3 ) ;
297
297
expect ( spy . calls . argsFor ( 1 ) [ 0 ] ) . toEqual ( {
298
298
formattedValue : '1334_' ,
299
299
value : '34' ,
300
300
floatValue : 34 ,
301
301
} ) ;
302
- } )
302
+ } ) ;
303
303
304
304
it ( 'should not allow replacing all characters with number when formatting is present for NumericFormats' , ( ) => {
305
305
//check for numeric input
@@ -558,7 +558,7 @@ describe('NumberFormat as input', () => {
558
558
559
559
it ( 'should not give wrong value, when user enter more number than the given hash in PatternFormat #712' , async ( ) => {
560
560
const Component = ( ) => {
561
- const [ value , setValue ] = useState ( " 1232345124" ) ;
561
+ const [ value , setValue ] = useState ( ' 1232345124' ) ;
562
562
return (
563
563
< div >
564
564
< PatternFormat
@@ -572,17 +572,17 @@ describe('NumberFormat as input', () => {
572
572
/>
573
573
< span data-testid = "value" > { value } </ span >
574
574
</ div >
575
- )
576
- }
575
+ ) ;
576
+ } ;
577
577
578
- const { input, view} = await render ( < Component /> ) ;
578
+ const { input, view } = await render ( < Component /> ) ;
579
579
simulateNativeKeyInput ( input , '1' , 1 , 1 ) ;
580
580
await wait ( 100 ) ;
581
581
582
582
expect ( input . value ) . toEqual ( '(112) 3234 512' ) ;
583
583
const value = await view . getByTestId ( 'value' ) ;
584
584
expect ( value . innerText ) . toEqual ( '1123234512' ) ;
585
- } )
585
+ } ) ;
586
586
587
587
describe ( 'Test masking' , ( ) => {
588
588
it ( 'should allow mask as string' , ( ) => {
0 commit comments