DOMCore test bugs:

I've found a few problems trying to run the DOM Core .html tests.

1) 
webapps/DOMCore/tests/submissions/Ms2ger/Document-getElementsByTagName.html
> test(function() {
>   var l = document.getElementsByTagName("nosuchtag")
>   l[5] = "foopy"
>   assert_equals(l.item(5), null)
> }, "Expandos shouldn't affect item()")

This test is incorrect: §4.7.3 of WebIDL (steps 2.4 and 2.5) say that 
the attempt to set l[5] should throw TypeError.  This is different than 
what most web browsers do today, I think.

2) webapps/DOMCore/tests/submissions/Ms2ger/Element-tagName.html

this test relies on DOMParser, which means that simple DOM Core 
implementations can't run it.

3) webapps/DOMCore/tests/submissions/Ms2ger/Node-appendChild.html
webapps/DOMCore/tests/submissions/Ms2ger/Node-removeChild.html

These two tests use frames[], so DOM Core implementations that don't 
support that property can't run them.

4) webapps/DOMCore/tests/submissions/Ms2ger/Node-hasAttributes.html

This one tests for hasAttributes() which has been explicitly removed 
from the DOM Core spec.

5) webapps/DOMCore/tests/submissions/Ms2ger/Node-insertBefore.html

This test treats Attr objects like nodes, but DOM Core says they are not 
nodes.

     David

Received on Wednesday, 3 August 2011 21:02:10 UTC