Android
junit.framework
public class

junit.framework.TestFailure

java.lang.Object
junit.framework.TestFailure

A TestFailure collects a failed test together with the caught exception.

See Also

Summary

Fields

protected      Test  fFailedTest   
protected      Throwable  fThrownException   

Public Constructors

            TestFailure(Test failedTest, Throwable thrownException)
Constructs a TestFailure with the given test and exception.

Public Methods

          String  exceptionMessage()
          Test  failedTest()
Gets the failed test.
          boolean  isFailure()
          Throwable  thrownException()
Gets the thrown exception.
          String  toString()
Returns a short description of the failure.
          String  trace()
Methods inherited from class java.lang.Object

Details

Fields

protected Test fFailedTest

protected Throwable fThrownException

Public Constructors

public TestFailure(Test failedTest, Throwable thrownException)

Constructs a TestFailure with the given test and exception.

Public Methods

public String exceptionMessage()

public Test failedTest()

Gets the failed test.

public boolean isFailure()

public Throwable thrownException()

Gets the thrown exception.

public String toString()

Returns a short description of the failure.

Returns

  • String a printable representation for the receiver.

public String trace()

Copyright 2007 Google Inc. Build 0.9_r1-98467 - 14 Aug 2008 18:48