@@ -651,7 +651,7 @@ describe('React', () => {
651
651
) }
652
652
</ ProviderMock > ,
653
653
)
654
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
654
+ expect ( spy ) . toHaveBeenCalledOnce ( )
655
655
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
656
656
/ m a p S t a t e T o P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
657
657
)
@@ -668,7 +668,7 @@ describe('React', () => {
668
668
) }
669
669
</ ProviderMock > ,
670
670
)
671
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
671
+ expect ( spy ) . toHaveBeenCalledOnce ( )
672
672
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
673
673
/ m a p S t a t e T o P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
674
674
)
@@ -685,7 +685,7 @@ describe('React', () => {
685
685
) }
686
686
</ ProviderMock > ,
687
687
)
688
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
688
+ expect ( spy ) . toHaveBeenCalledOnce ( )
689
689
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
690
690
/ m a p S t a t e T o P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
691
691
)
@@ -702,7 +702,7 @@ describe('React', () => {
702
702
) }
703
703
</ ProviderMock > ,
704
704
)
705
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
705
+ expect ( spy ) . toHaveBeenCalledOnce ( )
706
706
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
707
707
/ m a p D i s p a t c h T o P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
708
708
)
@@ -719,7 +719,7 @@ describe('React', () => {
719
719
) }
720
720
</ ProviderMock > ,
721
721
)
722
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
722
+ expect ( spy ) . toHaveBeenCalledOnce ( )
723
723
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
724
724
/ m a p D i s p a t c h T o P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
725
725
)
@@ -736,7 +736,7 @@ describe('React', () => {
736
736
) }
737
737
</ ProviderMock > ,
738
738
)
739
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
739
+ expect ( spy ) . toHaveBeenCalledOnce ( )
740
740
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
741
741
/ m a p D i s p a t c h T o P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
742
742
)
@@ -753,7 +753,7 @@ describe('React', () => {
753
753
) }
754
754
</ ProviderMock > ,
755
755
)
756
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
756
+ expect ( spy ) . toHaveBeenCalledOnce ( )
757
757
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
758
758
/ m e r g e P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
759
759
)
@@ -770,7 +770,7 @@ describe('React', () => {
770
770
) }
771
771
</ ProviderMock > ,
772
772
)
773
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
773
+ expect ( spy ) . toHaveBeenCalledOnce ( )
774
774
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
775
775
/ m e r g e P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
776
776
)
@@ -787,7 +787,7 @@ describe('React', () => {
787
787
) }
788
788
</ ProviderMock > ,
789
789
)
790
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
790
+ expect ( spy ) . toHaveBeenCalledOnce ( )
791
791
expect ( spy . mock . calls [ 0 ] [ 0 ] ) . toMatch (
792
792
/ m e r g e P r o p s \( \) i n C o n n e c t \( C o n t a i n e r \) m u s t r e t u r n a p l a i n o b j e c t / ,
793
793
)
@@ -1488,7 +1488,7 @@ describe('React', () => {
1488
1488
< ConnectedContainer />
1489
1489
</ ProviderMock > ,
1490
1490
)
1491
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
1491
+ expect ( spy ) . toHaveBeenCalledOnce ( )
1492
1492
expect ( tester . getByTestId ( 'string' ) ) . toHaveTextContent ( '' )
1493
1493
rtl . act ( ( ) => {
1494
1494
store . dispatch ( { type : 'APPEND' , body : 'a' } )
@@ -1583,7 +1583,7 @@ describe('React', () => {
1583
1583
}
1584
1584
1585
1585
const tester = rtl . render ( < Root /> )
1586
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
1586
+ expect ( spy ) . toHaveBeenCalledOnce ( )
1587
1587
expect ( tester . getByTestId ( 'string' ) ) . toHaveTextContent ( '' )
1588
1588
expect ( tester . getByTestId ( 'pass' ) ) . toHaveTextContent ( '' )
1589
1589
@@ -2051,7 +2051,7 @@ describe('React', () => {
2051
2051
</ ProviderMock > ,
2052
2052
)
2053
2053
2054
- expect ( mapStateToProps ) . toHaveBeenCalledTimes ( 1 )
2054
+ expect ( mapStateToProps ) . toHaveBeenCalledOnce ( )
2055
2055
rtl . act ( ( ) => {
2056
2056
store . dispatch ( { type : 'INC' } )
2057
2057
} )
@@ -2114,11 +2114,11 @@ describe('React', () => {
2114
2114
rtl . act ( ( ) => {
2115
2115
store . dispatch ( { type : 'INC' } )
2116
2116
} )
2117
- expect ( mapStateToProps ) . toHaveBeenCalledTimes ( 1 )
2117
+ expect ( mapStateToProps ) . toHaveBeenCalledOnce ( )
2118
2118
rtl . act ( ( ) => {
2119
2119
store . dispatch ( { type : 'INC' } )
2120
2120
} )
2121
- expect ( mapStateToProps ) . toHaveBeenCalledTimes ( 1 )
2121
+ expect ( mapStateToProps ) . toHaveBeenCalledOnce ( )
2122
2122
} )
2123
2123
} )
2124
2124
@@ -2381,9 +2381,9 @@ describe('React', () => {
2381
2381
expect ( tester . getByTestId ( 'b' ) ) . toHaveTextContent ( '3' )
2382
2382
expect ( tester . getByTestId ( 'c' ) ) . toHaveTextContent ( '1' )
2383
2383
2384
- expect ( c3Spy ) . toHaveBeenCalledTimes ( 1 )
2385
- expect ( c2Spy ) . toHaveBeenCalledTimes ( 1 )
2386
- expect ( c1Spy ) . toHaveBeenCalledTimes ( 1 )
2384
+ expect ( c3Spy ) . toHaveBeenCalledOnce ( )
2385
+ expect ( c2Spy ) . toHaveBeenCalledOnce ( )
2386
+ expect ( c1Spy ) . toHaveBeenCalledOnce ( )
2387
2387
2388
2388
rtl . act ( ( ) => {
2389
2389
store1 . dispatch ( { type : 'CHANGE' } )
@@ -2395,7 +2395,7 @@ describe('React', () => {
2395
2395
expect ( tester . getByTestId ( 'c' ) ) . toHaveTextContent ( '2' )
2396
2396
2397
2397
expect ( c3Spy ) . toHaveBeenCalledTimes ( 2 )
2398
- expect ( c2Spy ) . toHaveBeenCalledTimes ( 1 )
2398
+ expect ( c2Spy ) . toHaveBeenCalledOnce ( )
2399
2399
expect ( c1Spy ) . toHaveBeenCalledTimes ( 2 )
2400
2400
2401
2401
rtl . act ( ( ) => {
@@ -2485,16 +2485,16 @@ describe('React', () => {
2485
2485
</ ProviderMock >
2486
2486
</ ProviderMock > ,
2487
2487
)
2488
- expect ( mapStateToPropsB ) . toHaveBeenCalledTimes ( 1 )
2489
- expect ( mapStateToPropsC ) . toHaveBeenCalledTimes ( 1 )
2490
- expect ( mapStateToPropsD ) . toHaveBeenCalledTimes ( 1 )
2488
+ expect ( mapStateToPropsB ) . toHaveBeenCalledOnce ( )
2489
+ expect ( mapStateToPropsC ) . toHaveBeenCalledOnce ( )
2490
+ expect ( mapStateToPropsD ) . toHaveBeenCalledOnce ( )
2491
2491
2492
2492
rtl . act ( ( ) => {
2493
2493
store1 . dispatch ( { type : 'INC' } )
2494
2494
} )
2495
2495
2496
- expect ( mapStateToPropsB ) . toHaveBeenCalledTimes ( 1 )
2497
- expect ( mapStateToPropsC ) . toHaveBeenCalledTimes ( 1 )
2496
+ expect ( mapStateToPropsB ) . toHaveBeenCalledOnce ( )
2497
+ expect ( mapStateToPropsC ) . toHaveBeenCalledOnce ( )
2498
2498
expect ( mapStateToPropsD ) . toHaveBeenCalledTimes ( 2 )
2499
2499
2500
2500
rtl . act ( ( ) => {
@@ -2955,7 +2955,7 @@ describe('React', () => {
2955
2955
</ ProviderMock > ,
2956
2956
)
2957
2957
2958
- expect ( spy ) . toHaveBeenCalledTimes ( 1 )
2958
+ expect ( spy ) . toHaveBeenCalledOnce ( )
2959
2959
expect ( spy ) . toHaveBeenCalledWith (
2960
2960
'The `pure` option has been removed. `connect` is now always a "pure/memoized" component' ,
2961
2961
)
0 commit comments