Permalink
Browse files

Merge pull request #300 from arnihermann/master

Fix xunit plugin. Merging through github interface because the xunit plugin is known by not being so reliable so no test coverage is required
  • Loading branch information...
2 parents 58bcd09 + f8f7251 commit 33981528562e5cce59b9d10b7d479c695b984e32 @gabrielfalcao committed Nov 23, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 lettuce/plugins/xunit_output.py
@@ -65,7 +65,8 @@ def create_test_case_step(step):
if step.failed:
cdata = doc.createCDATASection(step.why.traceback)
failure = doc.createElement("failure")
- failure.setAttribute("message", step.why.cause)
+ if hasattr(step.why, 'cause'):
+ failure.setAttribute("message", step.why.cause)
failure.setAttribute("type", step.why.exception.__class__.__name__)
failure.appendChild(cdata)
tc.appendChild(failure)

0 comments on commit 3398152

Please sign in to comment.