Closed Bug 601756 Opened 14 years ago Closed 14 years ago

Tests for TreeWalker.nextSibling, previousSibling, as suggested by Traversal spec

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla2.0b8

People

(Reporter: WeirdAl, Assigned: WeirdAl)

References

()

Details

(Keywords: testcase)

Attachments

(1 file)

"Omitting nodes from the logical view of a subtree can result in a structure that is substantially different from the same subtree in the complete, unfiltered document. Nodes that are siblings in the TreeWalker view may be children of different, widely separated nodes in the original view. For instance, consider a NodeFilter that skips all nodes except for Text nodes and the root node of a document. In the logical view that results, all text nodes will be siblings and appear as direct children of the root node, no matter how deeply nested the structure of the original document."

I wasn't quite sure we were doing this right, but we are - and we're consistent with nextSibling(), .previousSibling().  This test passes with flying colors.
Attachment #480750 - Flags: superreview?(Olli.Pettay)
Attachment #480750 - Flags: review?(Olli.Pettay)
Attachment #480750 - Flags: superreview?(Olli.Pettay)
Attachment #480750 - Flags: review?(Olli.Pettay)
Attachment #480750 - Flags: review+
Keywords: checkin-needed
http://hg.mozilla.org/mozilla-central/rev/ba950e2f4066
Status: NEW → RESOLVED
Closed: 14 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b8
Component: DOM: Traversal-Range → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: