diff --git a/CHANGELOG b/CHANGELOG index d332c1d..ccf7b6a 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,5 @@ +* Add unit tests for Element#descendantOf. (jddalton) + * Form#serializeElements should not serialize file inputs. (kangax, Lonesome Boy) * Fix an issue with calling Event.pointer before the DOM is loaded. (kangax, jddalton) [#4 state:resolved] diff --git a/test/unit/dom_test.js b/test/unit/dom_test.js index 1d51c36..4776924 100644 --- a/test/unit/dom_test.js +++ b/test/unit/dom_test.js @@ -715,6 +715,10 @@ new Test.Unit.Runner({ $(document.body).insert(new Element('div', { id: 'impostor' })); this.assert(!$('impostor').descendantOf('ancestor')); + + // test descendantOf document + this.assert($(document.body).descendantOf(document)); + this.assert($(document.documentElement).descendantOf(document)); }, testChildOf: function() {