Two questions

The last couple of days I have been putting together a test suite for
javadom.py, which is a simple wrapper interface that allows Python
scripts running in JPython to use Java DOM implementations with a
Python DOM interface.

When writing this test suite I found a number of bugs in the
underlying DOM implementations (and, of course, my own interface),
which I have reported. I also found a couple of weak spots, I believe,
in the specifications, where implementations differ.


1. What is the result of
document.createAttribute("a")._get_nodeValue()?

  Is it None or ""?  As far as I can see neither of the level 1 and
  level 2 specs answer this question.  None would be the most
  reasonable answer, methinks, but some implementations think
  otherwise.

  Xerces:   ""
  Sun:      None
  Brownell: ""
  4DOM:     ""
  Indelv:   None
  SXP:      None
  OpenXML:  ""

2. What is the result of calling
element.removeAttribute("non-existent")?

  The specs (1 and 2) seem to say that nothing should happen, and that
  is my own interpretation. 

  Xerces:   nothing
  Sun:      raise DOMException
  Brownell: raise DOMException
  4DOM:     nothing
  Indelv:   nothing
  SXP:      nothing
  OpenXML:  nothing


--Lars M.

Received on Sunday, 21 May 2000 11:02:11 UTC