aboutsummaryrefslogtreecommitdiffstats
path: root/src/jquery/coreTest.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/jquery/coreTest.js')
-rw-r--r--src/jquery/coreTest.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/jquery/coreTest.js b/src/jquery/coreTest.js
index 18fed649e..d0fc9d25e 100644
--- a/src/jquery/coreTest.js
+++ b/src/jquery/coreTest.js
@@ -849,6 +849,14 @@ test("not()", function() {
isSet( $("p").not($("#ap, #sndp, .result")).get(), q("firstp", "en", "sap", "first"), "not(jQuery)" );
});
+test("andSelf()", function() {
+ expect(4);
+ isSet( $("#en").siblings().andSelf().get(), q("sndp", "sap","en"), "Check for siblings and self" );
+ isSet( $("#foo").children().andSelf().get(), q("sndp", "en", "sap", "foo"), "Check for children and self" );
+ isSet( $("#en, #sndp").parent().andSelf().get(), q("foo","en","sndp"), "Check for parent and self" );
+ isSet( $("#groups").parents("p, div").andSelf().get(), q("ap", "main", "groups"), "Check for parents and self" );
+});
+
test("siblings([String])", function() {
expect(5);
isSet( $("#en").siblings().get(), q("sndp", "sap"), "Check for siblings" );