Interface FailureFactory

All Known Subinterfaces:
FailureHandler
All Known Implementing Classes:
DefaultFailureHandler, DefaultFailureHandler.DefaultFailureFactory, DiffCollectingFailureHandler, JUnitFailureFactory

public interface FailureFactory
Factory to create exceptions for the testing framework to be used, for example JUnit, TestNG or dbunit exceptions.
Since:
2.4.0
Version:
$Revision$ $Date$
Author:
gommma (gommma AT users.sourceforge.net), Last changed by: $Author$
  • Method Summary

    Modifier and Type
    Method
    Description
     
    createFailure(String message, String expected, String actual)
    Creates a new failure object which can have different types, depending on the testing framework you are currently using (e.g.
  • Method Details

    • createFailure

      Error createFailure(String message, String expected, String actual)
      Creates a new failure object which can have different types, depending on the testing framework you are currently using (e.g. JUnit, TestNG, ...)
      Parameters:
      message - The reason for the failure
      expected - The expected result
      actual - The actual result
      Returns:
      The comparison failure object for this handler (can be JUnit or some other) which can be thrown on an assertion failure
    • createFailure

      Error createFailure(String message)
      Parameters:
      message - The reason for the failure
      Returns:
      The assertion failure object for this handler (can be JUnit or some other) which can be thrown on an assertion failure