@@ -22,7 +22,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, config }) => {
2222 } ) ;
2323
2424 test . describe ( title ( 'input password toggle: aria attributes' ) , ( ) => {
25- test ( 'should inherit aria attributes to inner button on load' , async ( { page } ) => {
25+ test ( 'should have correct aria attributes on load' , async ( { page } ) => {
2626 await page . setContent (
2727 `
2828 <ion-input label="input" type="password">
@@ -35,9 +35,9 @@ configs({ directions: ['ltr'] }).forEach(({ title, config }) => {
3535 const nativeButton = page . locator ( 'ion-input-password-toggle button' ) ;
3636
3737 await expect ( nativeButton ) . toHaveAttribute ( 'aria-label' , 'Show password' ) ;
38- await expect ( nativeButton ) . toHaveAttribute ( 'aria-checked ' , 'false' ) ;
38+ await expect ( nativeButton ) . toHaveAttribute ( 'aria-pressed ' , 'false' ) ;
3939 } ) ;
40- test ( 'should inherit aria attributes to inner button after toggle' , async ( { page } ) => {
40+ test ( 'should update aria attributes after toggle' , async ( { page } ) => {
4141 await page . setContent (
4242 `
4343 <ion-input label="input" type="password">
@@ -51,7 +51,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, config }) => {
5151 await nativeButton . click ( ) ;
5252
5353 await expect ( nativeButton ) . toHaveAttribute ( 'aria-label' , 'Hide password' ) ;
54- await expect ( nativeButton ) . toHaveAttribute ( 'aria-checked ' , 'true' ) ;
54+ await expect ( nativeButton ) . toHaveAttribute ( 'aria-pressed ' , 'true' ) ;
5555 } ) ;
5656 } ) ;
5757} ) ;
0 commit comments