History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: XFIRE-921
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Tomasz Sztelak
Reporter: Bryan Brouckaert
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
XFire

org.codehaus.xfire.test.XPathAssert.assertXPathEquals() does not support attributes

Created: 21/Mar/07 05:07 AM   Updated: 22/Apr/07 11:08 AM
Component/s: Core
Affects Version/s: 1.2.5
Fix Version/s: 1.2.6

Time Tracking:
Not Specified

File Attachments: 1. Text File attribute.patch (0.5 kb)



 Description  « Hide
When executing a statement like this:
assertXPathEquals("//s:Body/rdb:country/@id", "1", doc);

The following exception is thrown:

java.lang.ClassCastException: org.jdom.Attribute
        at org.codehaus.xfire.test.XPathAssert.assertXPathEquals(XPathAssert.java:112)
        at org.codehaus.xfire.test.AbstractXFireTest.assertXPathEquals(AbstractXFireTest.java:305)
        ...

This is because the resulting node is cast to org.jdom.Content, but org.jdom.Attribute does not inherit from that class. I made a patch that checks the type of the resulting node.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Tomasz Sztelak - 22/Apr/07 11:08 AM
Fixed in svn.