Class TestResult

java.lang.Object
org.citrusframework.TestResult

public final class TestResult extends Object
Class representing test results (failed, successful, skipped)
Author:
Christoph Deppisch
  • Method Details

    • success

      public static TestResult success(String name, String className)
      Create new test result for successful execution.
    • success

      public static TestResult success(String name, String className, Map<String,Object> parameters)
      Create new test result with parameters for successful execution.
    • skipped

      public static TestResult skipped(String name, String className)
      Create new test result for skipped test.
    • skipped

      public static TestResult skipped(String name, String className, @Nonnull Map<String,Object> parameters)
      Create new test result with parameters for skipped test.
    • failed

      public static TestResult failed(String name, String className, @Nullable Throwable cause)
      Create new test result for failed execution.
    • failed

      public static TestResult failed(String name, String className, @Nonnull String errorMessage)
      Create new test result for failed execution.
    • failed

      public static TestResult failed(String name, String className, @Nullable Throwable cause, @Nonnull Map<String,Object> parameters)
      Create new test result with parameters for failed execution.
    • isSuccess

      public boolean isSuccess()
    • isFailed

      public boolean isFailed()
    • isSkipped

      public boolean isSkipped()
    • getResult

      public String getResult()
    • getTestName

      public String getTestName()
    • getClassName

      public String getClassName()
    • getParameters

      public Map<String,Object> getParameters()
    • getCause

      @Nullable public Throwable getCause()
    • getErrorMessage

      @Nullable public String getErrorMessage()
    • getFailureStack

      @Nullable public String getFailureStack()
    • getFailureType

      @Nullable public String getFailureType()
    • withFailureType

      public TestResult withFailureType(String failureType)
    • getDuration

      @Nullable public Duration getDuration()
    • withDuration

      public TestResult withDuration(Duration duration)
    • toString

      public String toString()
      Overrides:
      toString in class Object