aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/core.js
diff options
context:
space:
mode:
authorJohn Resig <jeresig@gmail.com>2008-12-31 19:21:24 +0000
committerJohn Resig <jeresig@gmail.com>2008-12-31 19:21:24 +0000
commit6a3d1a1e281a5d13bca1ea388ae2bd8ce513ffb2 (patch)
tree9a878d4abd2c6190a2deb048363c868f146a48df /test/unit/core.js
parentc7a14f13916ca8ed22f9bb6fe40fa104b370211f (diff)
downloadjquery-6a3d1a1e281a5d13bca1ea388ae2bd8ce513ffb2.tar.gz
jquery-6a3d1a1e281a5d13bca1ea388ae2bd8ce513ffb2.zip
Fixed an issue with .not("#foo, bar") not working correctly, closes #3757.
Diffstat (limited to 'test/unit/core.js')
-rw-r--r--test/unit/core.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/unit/core.js b/test/unit/core.js
index 1f0850c02..71bfc8118 100644
--- a/test/unit/core.js
+++ b/test/unit/core.js
@@ -1345,7 +1345,7 @@ test("closest()", function() {
});
test("not()", function() {
- expect(8);
+ expect(11);
equals( jQuery("#main > p#ap > a").not("#google").length, 2, "not('selector')" );
equals( jQuery("#main > p#ap > a").not(document.getElementById("google")).length, 2, "not(DOMElement)" );
isSet( jQuery("p").not(".result").get(), q("firstp", "ap", "sndp", "en", "sap", "first"), "not('.class')" );
@@ -1356,6 +1356,10 @@ test("not()", function() {
var selects = jQuery("#form select");
isSet( selects.not( selects[1] ), q("select1", "select3"), "filter out DOM element");
+
+ isSet( jQuery('#ap *').not('code'), q("google", "groups", "anchor1", "mark"), "not('tag selector')" );
+ isSet( jQuery('#ap *').not('code, #mark'), q("google", "groups", "anchor1"), "not('tag, ID selector')" );
+ isSet( jQuery('#ap *').not('#mark, code'), q("google", "groups", "anchor1"), "not('ID, tag selector')");
});
test("andSelf()", function() {