michael@0:
michael@0:
michael@0:
michael@0:
michael@0: Test for Bug 419527
michael@0:
michael@0:
michael@0:
michael@0:
michael@0: Foo
michael@0:
michael@0:
michael@0:
michael@0: var win = XPCNativeWrapper.unwrap(window);
michael@0: var span = document.getAnonymousNodes(this)[0];
michael@0: win.ok(span.localName == "span", "Wrong anon node!");
michael@0: var range = document.createRange();
michael@0: range.selectNode(span.firstChild);
michael@0: win.ok(range.startContainer == span, "Wrong start container!");
michael@0: win.ok(range.endContainer == span, "Wrong end container!");
michael@0: var newSubTree = XPCNativeWrapper(win.newSubTree);
michael@0: newSubTree.appendChild(this);
michael@0: range.setStart(newSubTree.firstChild, 0);
michael@0: win.ok(range.startContainer == newSubTree.firstChild,
michael@0: "Range should have been collapsed to newSubTree.firstChild!");
michael@0: win.ok(range.endContainer == newSubTree.firstChild,
michael@0: "Range should have been collapsed to newSubTree.firstChild!");
michael@0: //XXX This should just call SimpleTest.finish(), bugs 478528, 499735.
michael@0: setTimeout(win.finish, 0);
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0: Mozilla Bug 419527
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0:
michael@0: