Menu

#355 ParsedHTML.getDOM throwing DOMException.NOT_SUPPORTED_ERR

closed-duplicate
None
5
2008-04-01
2006-05-02
Pete
No

We are using jWebUnit for integration testing our web
application. This in turn uses HttpUnit for parsing
and inspecting the web responses.

Whilst using these tools we have found that when
calling the getElement method in HttpUnitDialog (from
jWebUnit), which calls through to ParsedHTML.getDOM,
the Xerces call:

getRootNode().cloneNode( /* deep */ true );

results in a DOMException being thrown.

It would appear that the importNode method in the
CoreDocumentImpl class does not provide an
implementation for cloning a node of type
DOCUMENT_NODE.

We cannot see any good reason why the getDom method in
ParsedHTML is calling cloneNode. This should perhaps
be in a seperate method.

For now, we have fixed our problem by simply removing
the call to cloneNode in getDOM. This feels like a
hack though and a more suitable solution would be
desirable.

Discussion

  • Wolfgang Fahl

    Wolfgang Fahl - 2008-04-01
    • assigned_to: nobody --> russgold
    • status: open --> closed-duplicate
     

Log in to post a comment.

MongoDB Logo MongoDB