Another issue

With the changes mentioned in the previous message, the classic Xerces-J (can't remember the exact version) that I've been using as a benchmark only fails one test (elementreplaceattributewithself) in default mode.

elementreplaceattributewithself is a test that I introduced when discovering that elementinuseattributeerr was unintentionally testing this behavior.

From http://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#method-setAttributeNode

setAttributeNode ...

INUSE_ATTRIBUTE_ERR: Raised if newAttr is already an attribute of another Element object. The DOM user must explicitly clone Attr nodes to re-use them in other elements.

elementreplaceattributewithself tests the behavior when setAttributeNode is called with an attribute that is already on use on the SAME object.  Since newAttr does not meet the criteria to throw an INUSE_ATTRIBUTE_ERR, this test expects that setAttributeNode will not throw an exception and to basically do nothing.

I believe the test reflects the wording of the spec.  However, if Xerces-J existing behavior is deemed acceptible, then the phase "another Element" should be replaced with "any Element".

Received on Tuesday, 29 January 2002 02:20:17 UTC