@@ -89,17 +89,17 @@ test( "_renderButtonItem()", function() {
89
89
element . selectmenu ( "refresh" ) ;
90
90
option = element . find ( "option:selected" ) ;
91
91
equal (
92
- " " + option . text ( ) + element [ 0 ] . selectedIndex ,
93
- button . text ( ) ,
92
+ $ . trim ( button . text ( ) ) ,
93
+ option . text ( ) + element [ 0 ] . selectedIndex ,
94
94
"refresh: button item text"
95
95
) ;
96
96
97
97
button . trigger ( "click" ) ;
98
98
menu . find ( "li" ) . last ( ) . simulate ( "mouseover" ) . trigger ( "click" ) ;
99
99
option = element . find ( "option" ) . last ( ) ;
100
100
equal (
101
- " " + option . text ( ) + element [ 0 ] . selectedIndex ,
102
- button . text ( ) ,
101
+ $ . trim ( button . text ( ) ) ,
102
+ option . text ( ) + element [ 0 ] . selectedIndex ,
103
103
"click: button item text"
104
104
) ;
105
105
} ) ;
@@ -146,7 +146,7 @@ $.each( [
146
146
selected . val ( ) ,
147
147
"original select state"
148
148
) ;
149
- equal ( button . text ( ) , " " + selected . text ( ) , "button text" ) ;
149
+ equal ( $ . trim ( button . text ( ) ) , selected . text ( ) , "button text" ) ;
150
150
start ( ) ;
151
151
} ) ;
152
152
} ) ;
@@ -181,7 +181,7 @@ $.each( [
181
181
selected . val ( ) ,
182
182
"original select state"
183
183
) ;
184
- equal ( button . text ( ) , " " + selected . text ( ) , "button text" ) ;
184
+ equal ( $ . trim ( button . text ( ) ) , selected . text ( ) , "button text" ) ;
185
185
start ( ) ;
186
186
} , 1 ) ;
187
187
} ) ;
@@ -222,7 +222,7 @@ $.each( [
222
222
"button aria-activedescendant" ) ;
223
223
equal ( element . find ( "option:selected" ) . val ( ) , options . eq ( 1 ) . val ( ) ,
224
224
"original select state" ) ;
225
- equal ( button . text ( ) , " " + options . eq ( 1 ) . text ( ) , "button text" ) ;
225
+ equal ( $ . trim ( button . text ( ) ) , options . eq ( 1 ) . text ( ) , "button text" ) ;
226
226
start ( ) ;
227
227
} ) ;
228
228
} ) ;
0 commit comments