@@ -22,9 +22,11 @@ test("change", function () {
22
22
var widget = this . element . selectmenu ( "widget" ) ,
23
23
menu = widget . filter ( ".ui-selectmenu-menu" ) ,
24
24
button = widget . filter ( ".ui-selectmenu-button" ) ,
25
+ link = button . find ( "a" ) ,
25
26
value = this . element . find ( "option" ) . first ( ) . text ( ) ;
26
-
27
- button . find ( "a" ) . simulate ( "click" ) ;
27
+
28
+ link . simulate ( "focus" ) ;
29
+ link . simulate ( "click" ) ;
28
30
menu . find ( "a" ) . first ( ) . simulate ( "mouseover" ) . simulate ( "click" ) ;
29
31
} ) ;
30
32
@@ -40,6 +42,11 @@ test("close", function () {
40
42
}
41
43
} ) ;
42
44
45
+ var widget = this . element . selectmenu ( "widget" ) ,
46
+ button = widget . filter ( ".ui-selectmenu-button" ) ,
47
+ link = button . find ( "a" ) ;
48
+
49
+ link . simulate ( "focus" ) ;
43
50
this . element . selectmenu ( "open" ) . selectmenu ( "close" ) ;
44
51
} ) ;
45
52
@@ -63,9 +70,11 @@ test("focus", function () {
63
70
64
71
var widget = this . element . selectmenu ( "widget" ) ,
65
72
button = widget . filter ( ".ui-selectmenu-button" ) ,
73
+ link = button . find ( "a" ) ,
66
74
menu = widget . filter ( ".ui-selectmenu-menu" ) ;
67
75
68
- button . find ( "a" ) . simulate ( "click" ) ;
76
+ link . simulate ( "focus" ) ;
77
+ link . simulate ( "click" ) ;
69
78
menu . find ( ".ui-menu-item" ) . simulate ( "mouseover" ) ;
70
79
} ) ;
71
80
@@ -81,6 +90,11 @@ test("open", function () {
81
90
}
82
91
} ) ;
83
92
93
+ var widget = this . element . selectmenu ( "widget" ) ,
94
+ button = widget . filter ( ".ui-selectmenu-button" ) ,
95
+ link = button . find ( "a" ) ;
96
+
97
+ link . simulate ( "focus" ) ;
84
98
this . element . selectmenu ( "open" ) ;
85
99
} ) ;
86
100
@@ -99,9 +113,11 @@ test("select", function () {
99
113
100
114
var widget = this . element . selectmenu ( "widget" ) ,
101
115
button = widget . filter ( ".ui-selectmenu-button" ) ,
116
+ link = button . find ( "a" ) ,
102
117
menu = widget . filter ( ".ui-selectmenu-menu" ) ;
103
118
104
- button . find ( "a" ) . simulate ( "click" ) ;
119
+ link . simulate ( "focus" ) ;
120
+ link . simulate ( "click" ) ;
105
121
menu . find ( "a" ) . first ( ) . simulate ( "mouseover" ) . simulate ( "click" ) ;
106
122
} ) ;
107
123
0 commit comments