1
1
module ( "selector" ) ;
2
2
3
3
test ( "element" , function ( ) {
4
- expect ( 9 ) ;
4
+ expect ( 13 ) ;
5
5
reset ( ) ;
6
6
7
7
ok ( jQuery ( "*" ) . size ( ) >= 30 , "Select all" ) ;
@@ -18,6 +18,13 @@ test("element", function() {
18
18
19
19
ok ( jQuery ( "#length" ) . length , '<input name="length"> cannot be found under IE, see #945' ) ;
20
20
ok ( jQuery ( "#lengthtest input" ) . length , '<input name="length"> cannot be found under IE, see #945' ) ;
21
+
22
+ // Check for unique-ness and sort order
23
+ isSet ( jQuery ( "*" ) , jQuery ( "*, *" ) , "Check for duplicates: *, *" ) ;
24
+ isSet ( jQuery ( "p" ) , jQuery ( "p, div p" ) , "Check for duplicates: p, div p" ) ;
25
+
26
+ t ( "Checking sort order" , "h2, h1" , [ "header" , "banner" , "userAgent" ] ) ;
27
+ t ( "Checking sort order" , "p, p a" , [ "firstp" , "simon1" , "ap" , "google" , "groups" , "anchor1" , "mark" , "sndp" , "en" , "yahoo" , "sap" , "anchor2" , "simon" , "first" ] ) ;
21
28
} ) ;
22
29
23
30
if ( location . protocol != "file:" ) {
@@ -333,7 +340,7 @@ test("pseudo (:) selectors", function() {
333
340
t ( "Form element :text" , "#form :text" , [ "text1" , "text2" , "hidden2" , "name" ] ) ;
334
341
t ( "Form element :radio:checked" , "#form :radio:checked" , [ "radio2" ] ) ;
335
342
t ( "Form element :checkbox:checked" , "#form :checkbox:checked" , [ "check1" ] ) ;
336
- t ( "Form element :checkbox :checked, :radio :checked" , "#form :checkbox :checked, #form :radio :checked" , [ "check1 " , "radio2 " ] ) ;
343
+ t ( "Form element :radio :checked, :checkbox :checked" , "#form :radio :checked, #form :checkbox :checked" , [ "radio2 " , "check1 " ] ) ;
337
344
338
345
t ( "Headers" , ":header" , [ "header" , "banner" , "userAgent" ] ) ;
339
346
t ( "Has Children - :has()" , "p:has(a)" , [ "firstp" , "ap" , "en" , "sap" ] ) ;
0 commit comments