|
125 | 125 | var $popup = $( "#test-popup" ), |
126 | 126 | link = $( "a#open-test-popup" )[ 0 ]; |
127 | 127 |
|
128 | | - expect( 17 ); |
| 128 | + expect( 14 ); |
129 | 129 |
|
130 | 130 | $.testHelper.detailedEventCascade([ |
131 | 131 | function() { |
132 | | - deepEqual( $( "#test-popup-popup:visible" ).length, 0, "Test popup is not initially :visible" ); |
133 | 132 | deepEqual( $.mobile.getAttribute( link, "aria-haspopup" ), true, "'aria-haspopup' attribute is set to true on link that opens the popup" ); |
134 | 133 | deepEqual( $.mobile.getAttribute( link, "aria-owns" ), "#test-popup", "'aria-owns' attribute is set to the ID of the owned popup ('#test-popup')" ); |
135 | 134 | deepEqual( $.mobile.getAttribute( link, "aria-expanded" ), false, "'aria-expanded' attribute is set to false when the popup is not open" ); |
|
144 | 143 | function( result ) { |
145 | 144 | var theOffset = $( "#test-popup p" ).offset(); |
146 | 145 |
|
147 | | - deepEqual( $( "#test-popup-popup:visible" ).length, 1, "Test popup is :visible when open" ); |
148 | 146 | deepEqual( $.mobile.getAttribute( link, "aria-expanded" ), true, "'aria-expanded' attribute is set to true when the popup is open" ); |
149 | 147 | ok( !$popup.parent().prev().hasClass( "ui-screen-hidden" ), "Open popup screen is not hidden" ); |
150 | 148 | ok( $popup.attr( "class" ).match( /( |^)ui-body-[a-z]( |$)/ ), "Open popup has a valid overlay theme" ); |
|
164 | 162 | }, |
165 | 163 |
|
166 | 164 | function( result) { |
167 | | - deepEqual( $( "#test-popup-popup:visible" ).length, 0, "Test popup is not :visible after it is closed" ); |
168 | 165 | deepEqual( $.mobile.getAttribute( link, "aria-expanded" ), false, "'aria-expanded' attribute is set to false when the popup is not open" ); |
169 | 166 | ok( !$popup.parent().hasClass( "in" ), "Closed popup container does not have class 'in'" ); |
170 | 167 | ok( $popup.parent().prev().hasClass( "ui-screen-hidden" ), "Closed popup screen is hidden" ); |
|
0 commit comments