File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -87,14 +87,14 @@ describe('unit testing for Action.tsx', () => {
8787 test ( 'Clicking the snapshot should trigger onClick' , ( ) => {
8888 render ( < Action { ...props } /> ) ;
8989 fireEvent . click ( screen . getByRole ( 'presentation' ) ) ;
90- expect ( props . dispatch ) . toHaveBeenCalledWith ( changeView ( 2 ) ) ; ;
90+ expect ( props . dispatch ) . toHaveBeenCalledWith ( changeView ( props . index ) ) ; ;
9191 } ) ;
9292
9393 test ( 'Clicking Jump button should trigger changeSlider and changeView' , ( ) => {
9494 render ( < Action { ...props } /> ) ;
9595 fireEvent . click ( screen . getAllByRole ( 'button' ) [ 1 ] ) ;
96- expect ( props . dispatch ) . toHaveBeenCalledWith ( changeSlider ( 2 ) ) ;
97- expect ( props . dispatch ) . toHaveBeenCalledWith ( changeView ( 2 ) ) ;
96+ expect ( props . dispatch ) . toHaveBeenCalledWith ( changeSlider ( props . index ) ) ;
97+ expect ( props . dispatch ) . toHaveBeenCalledWith ( changeView ( props . index ) ) ;
9898 } ) ;
9999 } ) ;
100100} ) ;
You can’t perform that action at this time.
0 commit comments