Not sure if this counts as a bug, but when finding parents of a collection of more than one element the resulting collection has the parents in a back-to-front order at each tier. e.g
<div class="div1"><span></span></div><div class="div2"><span></span></div>
$("span").parents() // [div2, div1, body, html]
// expected [div1, div2, body, html]
Test case: http://jsfiddle.net/vkGEQ/
Original ticket: http://bugs.jquery.com/ticket/11385
This is by design , but the docs should mention it.
The bug ticket referenced above addresses the issue of the elements being returned from most closely nested to highest-level ancestor, but it doesn't mention the fact that sibling elements are returned backwards. Maybe this needs to go back in as a core bug separate from the above-referenced issue.
Also updated the fiddle example, as there was some incorrect markup (<p> tags not getting closed): http://jsfiddle.net/vkGEQ/4/
Clarify return of .parents() for non-unary sets. Close gh-4.