@@ -118,8 +118,24 @@ test( "accessibility", function() {
118
118
equal ( tabs . eq ( 2 ) . attr ( "aria-disabled" ) , "true" , "disabled tab has aria-disabled=true" ) ;
119
119
equal ( panels . eq ( 2 ) . attr ( "aria-expanded" ) , "false" , "inactive panel has aria-expanded=false" ) ;
120
120
equal ( panels . eq ( 2 ) . attr ( "aria-hidden" ) , "true" , "inactive panel has aria-hidden=true" ) ;
121
+ } ) ;
121
122
122
- // TODO: aria-live and aria-busy tests for ajax tabs
123
+ asyncTest ( "accessibility - ajax" , function ( ) {
124
+ expect ( 4 ) ;
125
+ var element = $ ( "#tabs2" ) . tabs ( ) ,
126
+ tab = element . find ( ".ui-tabs-nav li" ) . eq ( 3 ) ,
127
+ panel = $ ( "#custom-id" ) ;
128
+
129
+ equal ( panel . attr ( "aria-live" ) , "polite" , "remote panel has aria-live" ) ;
130
+ equal ( panel . attr ( "aria-busy" ) , null , "does not have aria-busy on init" ) ;
131
+ element . tabs ( "option" , "active" , 3 ) ;
132
+ equal ( panel . attr ( "aria-busy" ) , "true" , "panel has aria-busy during load" ) ;
133
+ element . one ( "tabsload" , function ( ) {
134
+ setTimeout ( function ( ) {
135
+ equal ( panel . attr ( "aria-busy" ) , null , "panel does not have aria-busy after load" ) ;
136
+ start ( ) ;
137
+ } , 1 ) ;
138
+ } ) ;
123
139
} ) ;
124
140
125
141
asyncTest ( "keyboard support - LEFT, RIGHT, UP, DOWN, HOME, END, SPACE, ENTER" , function ( ) {
0 commit comments