@@ -441,14 +441,35 @@ describe('Tabs', () => {
441441
442442 it ( `GIVEN 3 tabs and the focus is on the third,
443443 WHEN triggering the 'end' key
444- THEN the focus should be on the first tab` , ( ) => {
444+ THEN the focus should be on the last tab` , ( ) => {
445445 cy . mount ( < ThreeTabsComponent /> ) ;
446446
447447 cy . findByRole ( 'tab' , { name : / T a b 1 / i } ) . type ( '{end}' ) ;
448448
449449 cy . findByRole ( 'tab' , { name : / T a b 3 / i } ) . should ( 'have.focus' ) ;
450450 } ) ;
451451
452+ it . skip (
453+ `GIVEN 3 tabs on a long page and the focus is on the third,
454+ WHEN triggering the 'end' key
455+ THEN the focus should be on the last tab and page should not scroll` ,
456+ { scrollBehavior : false } ,
457+ ( ) => {
458+ cy . mount (
459+ < div >
460+ < div style = "height:900px" >
461+ < ThreeTabsComponent />
462+ </ div >
463+ < div data-testid = "scroll-target" > Outside</ div >
464+ </ div >
465+ ) ;
466+
467+ cy . findByRole ( 'tab' , { name : / T a b 1 / i } ) . type ( '{pageDown}' ) ;
468+
469+ cy . window ( ) . its ( 'scrollY' ) . should ( 'equal' , 0 ) ;
470+ }
471+ ) ;
472+
452473 it ( `GIVEN 3 tabs and the first is disabled and the focus is on the third,
453474 WHEN triggering the 'end' key
454475 THEN the focus should be on the second tab` , ( ) => {
0 commit comments