Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
odfdom-0.8.8
-
Ubuntu 11.04 64 bit, Intel i5, OpenJDK 1.6.0_20
Description
The getNamespaceURI() implementation in OdfFileDom is not aware of duplicate namespace prefixes. It is aware only of the default namespace prefixes, despite there being support for duplicate namespace prefixes in the implementation of OdfFileDom.
I am submitting a patched test case "xpathtest-case-patch.txt" and the corresponding odt file used by the test.
To simulate the problem –
1) apply the patch xpathtest-case-patch.txt on the ODFDOM source
2) put the XPathTest-duplicate-prefix.odt in odfdom/src/test/resources
3) Run the src/test/java/org/odftoolkit/odfdom/dom/XPathTest.java unit test. It fails.
4) apply the patch odffiledom-patch.txt on OdfFileDom and run the unit test again. It passes.
I have added explanatory comments in the patched unit test and the patched getNamespaceURI().