@@ -26,18 +26,18 @@ beforeEach(async () => {
2626 } ) ;
2727} ) ;
2828
29- it ( 'has the correct page title' , async ( ) => {
29+ it ( 'Has the correct page title' , async ( ) => {
3030 await expect ( page . title ( ) ) . resolves . toMatch ( 'React Accessible Dropdown Menu Hook' ) ;
3131} ) ;
3232
33- it ( 'leaves focus on the button after clicking it' , async ( ) => {
33+ it ( 'Leaves focus on the button after clicking it' , async ( ) => {
3434 await page . click ( '#menu-button' ) ;
3535 await menuOpen ( ) ;
3636
3737 expect ( await currentFocusID ( ) ) . toBe ( 'menu-button' ) ;
3838} ) ;
3939
40- it ( 'focuses on the menu button after pressing escape' , async ( ) => {
40+ it ( 'Focuses on the menu button after pressing escape' , async ( ) => {
4141 await page . focus ( '#menu-button' ) ;
4242 await page . keyboard . down ( 'Enter' ) ;
4343 await menuOpen ( ) ;
@@ -48,7 +48,7 @@ it('focuses on the menu button after pressing escape', async () => {
4848 expect ( await currentFocusID ( ) ) . toBe ( 'menu-button' ) ;
4949} ) ;
5050
51- it ( 'disables scroll by arrow key when menu is open' , async ( ) => {
51+ it ( 'Disables scroll by arrow key when menu is open' , async ( ) => {
5252 await page . setViewport ( {
5353 width : 1000 ,
5454 height : 500 ,
@@ -63,7 +63,7 @@ it('disables scroll by arrow key when menu is open', async () => {
6363 expect ( await page . evaluate ( ( ) => window . scrollY ) ) . toBe ( currentScrollY ) ;
6464} ) ;
6565
66- it ( 'does not disable scroll by arrow key when menu is closed' , async ( ) => {
66+ it ( 'Does not disable scroll by arrow key when menu is closed' , async ( ) => {
6767 await page . setViewport ( {
6868 width : 1000 ,
6969 height : 500 ,
@@ -75,7 +75,7 @@ it('does not disable scroll by arrow key when menu is closed', async () => {
7575 expect ( await page . evaluate ( ( ) => window . scrollY ) ) . toBeGreaterThan ( currentScrollY ) ;
7676} ) ;
7777
78- it ( 'focuses on the next item in the tab order after pressing tab' , async ( ) => {
78+ it ( 'Focuses on the next item in the tab order after pressing tab' , async ( ) => {
7979 await page . focus ( '#menu-button' ) ;
8080 await page . keyboard . down ( 'Enter' ) ;
8181 await menuOpen ( ) ;
@@ -86,7 +86,7 @@ it('focuses on the next item in the tab order after pressing tab', async () => {
8686 expect ( await currentFocusID ( ) ) . toBe ( 'first-footer-link' ) ;
8787} ) ;
8888
89- it ( 'focuses on the previous item in the tab order after pressing shift-tab' , async ( ) => {
89+ it ( 'Focuses on the previous item in the tab order after pressing shift-tab' , async ( ) => {
9090 await page . focus ( '#menu-button' ) ;
9191 await page . keyboard . down ( 'Enter' ) ;
9292 await menuOpen ( ) ;
@@ -98,7 +98,7 @@ it('focuses on the previous item in the tab order after pressing shift-tab', asy
9898 expect ( await currentFocusID ( ) ) . toBe ( 'menu-button' ) ;
9999} ) ;
100100
101- it ( 'closes the menu if you click outside of it' , async ( ) => {
101+ it ( 'Closes the menu if you click outside of it' , async ( ) => {
102102 await page . focus ( '#menu-button' ) ;
103103 await page . keyboard . down ( 'Enter' ) ;
104104 await menuOpen ( ) ;
@@ -109,7 +109,7 @@ it('closes the menu if you click outside of it', async () => {
109109 expect ( true ) . toBe ( true ) ;
110110} ) ;
111111
112- it ( 'leaves the menu open if you click inside of it' , async ( ) => {
112+ it ( 'Leaves the menu open if you click inside of it' , async ( ) => {
113113 await page . focus ( '#menu-button' ) ;
114114 await page . keyboard . down ( 'Enter' ) ;
115115 await menuOpen ( ) ;
@@ -135,7 +135,7 @@ it('leaves the menu open if you click inside of it', async () => {
135135 expect ( true ) . toBe ( true ) ;
136136} ) ;
137137
138- it ( 'reroutes enter presses on menu items as clicks' , async ( ) => {
138+ it ( 'Reroutes enter presses on menu items as clicks' , async ( ) => {
139139 let alertAppeared = false ;
140140
141141 await page . focus ( '#menu-button' ) ;
0 commit comments