org.jboss.osgi.husky.runtime.junit
Class JUnitFailure

java.lang.Object
  extended by org.jboss.osgi.husky.runtime.junit.JUnitFailure
All Implemented Interfaces:
Serializable, Failure

public class JUnitFailure
extends Object
implements Failure

A Failure implementation that can be constructed from a JUnit4 Failure.

Since:
16-May-2009
Author:
Thomas.Diesler@jboss.com
See Also:
Serialized Form

Constructor Summary
JUnitFailure(org.junit.runner.notification.Failure failure)
           
 
Method Summary
 String getClassName()
          Get the name of the test class that failed
 Throwable getException()
          Get the exceoption that caused the failure.
 String getMessage()
          Get the test failure message
 String getMethodName()
          Get the name of the test method that failed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JUnitFailure

public JUnitFailure(org.junit.runner.notification.Failure failure)
Method Detail

getClassName

public String getClassName()
Description copied from interface: Failure
Get the name of the test class that failed

Specified by:
getClassName in interface Failure

getMethodName

public String getMethodName()
Description copied from interface: Failure
Get the name of the test method that failed

Specified by:
getMethodName in interface Failure

getMessage

public String getMessage()
Description copied from interface: Failure
Get the test failure message

Specified by:
getMessage in interface Failure

getException

public Throwable getException()
Description copied from interface: Failure
Get the exceoption that caused the failure. In case of a failure due to an assertion, this will be RuntimeException or Error thrown by the test framework.

Specified by:
getException in interface Failure


Copyright © 2010 JBoss, a division of Red Hat, Inc.. All Rights Reserved.