Class StepInformationLogMessage

java.lang.Object
de.qytera.qtaf.core.log.model.message.LogMessage
de.qytera.qtaf.core.log.model.message.StepInformationLogMessage
Direct Known Subclasses:
CucumberStepLogMessage

public class StepInformationLogMessage extends LogMessage
Log message for called steps.
  • Constructor Details

    • StepInformationLogMessage

      public StepInformationLogMessage(String methodName, String message)
      Constructor.
      Parameters:
      methodName - step name
      message - log message
  • Method Details

    • getUuid

      public UUID getUuid()
      Get uuid.
      Returns:
      uuid
    • getStep

      Get step annotation.
      Returns:
      step annotation
    • setStep

      public StepInformationLogMessage setStep(Step step)
      Set step annotation.
      Parameters:
      step - step annotation
      Returns:
      this
    • setStepName

      public StepInformationLogMessage setStepName(String stepName)
      Set step name.
      Parameters:
      stepName - step name
      Returns:
      this
    • setStepDescription

      public StepInformationLogMessage setStepDescription(String stepDescription)
      Set step description.
      Parameters:
      stepDescription - step description
      Returns:
      this
    • addStepParameter

      public <T> void addStepParameter(String name, T value)
      Add a generic step parameter.
      Type Parameters:
      T - the type of the value object
      Parameters:
      name - the name of the parameter
      value - the value of the parameter
    • getStatus

      Get status.
      Returns:
      status Status
    • computeStatus

      public void computeStatus()
      Computes the status of the test step.
    • hasFailed

      public boolean hasFailed()
      Checks if step has failed.
      Returns:
      true if step has failed, false otherwise
    • hasPassed

      public boolean hasPassed()
      Checks if step has passed.
      Returns:
      true if step has passed, false otherwise
    • isPending

      public boolean isPending()
      Checks if step is pending.
      Returns:
      true if step is pending, false otherwise
    • isSkipped

      public boolean isSkipped()
      Checks if step is skipped.
      Returns:
      true if step is skipped, false otherwise
    • getResult

      public Object getResult()
      Get step result.
      Returns:
      step result
    • setResult

      public StepInformationLogMessage setResult(Object result)
      Set step result.
      Parameters:
      result - step result
      Returns:
      this
    • getError

      public ThrowableWrapper getError()
      Get step error.
      Returns:
      step error
    • hasError

      public boolean hasError()
      Check if an error occurred.
      Returns:
      true if an error occurred during method execution, false otherwise
    • setError

      public StepInformationLogMessage setError(Throwable error)
      Set step error.
      Parameters:
      error - step error
      Returns:
      this
    • setError

      Set step error.
      Parameters:
      error - step error
      Returns:
      this
    • getTYPE

      public String getTYPE()
      Get type.
      Returns:
      type
    • getMethodName

      public String getMethodName()
      Get methodName.
      Returns:
      methodName
    • setMethodName

      public StepInformationLogMessage setMethodName(String methodName)
      Set methodName.
      Parameters:
      methodName - MethodName
      Returns:
      this
    • setStatus

      Set status.
      Parameters:
      status - Status
      Returns:
      this
    • getStart

      public Date getStart()
      Get start.
      Returns:
      start
    • setStart

      public StepInformationLogMessage setStart(Date start)
      Set start.
      Parameters:
      start - Start
      Returns:
      this
    • getEnd

      public Date getEnd()
      Get end.
      Returns:
      end
    • setEnd

      public StepInformationLogMessage setEnd(Date end)
      Set end.
      Parameters:
      end - End
      Returns:
      this
    • getDuration

      public long getDuration()
      Get duration.
      Returns:
      duration
    • getScreenshotBefore

      public String getScreenshotBefore()
      Get screenshotBefore.
      Returns:
      screenshotBefore
    • setScreenshotBefore

      public StepInformationLogMessage setScreenshotBefore(String screenshotBefore)
      Set screenshotBefore.
      Parameters:
      screenshotBefore - ScreenshotBefore
      Returns:
      this
    • getScreenshotAfter

      public String getScreenshotAfter()
      Get screenshotAfter.
      Returns:
      screenshotAfter
    • setScreenshotAfter

      public StepInformationLogMessage setScreenshotAfter(String screenshotAfter)
      Set screenshotAfter.
      Parameters:
      screenshotAfter - ScreenshotAfter
      Returns:
      this
    • getAssertions

      public List<AssertionLogMessage> getAssertions()
      Get assertions.
      Returns:
      list of assertions
    • setAssertions

      public StepInformationLogMessage setAssertions(List<AssertionLogMessage> assertions)
      Set list of assertions.
      Parameters:
      assertions - list of assertions
      Returns:
      this
    • addAssertion

      public StepInformationLogMessage addAssertion(AssertionLogMessage assertion)
      Add an assertion to the list.
      Parameters:
      assertion - Assertion
      Returns:
      this
    • getStepParameters

      public List<StepInformationLogMessage.StepParameter> getStepParameters()
      The list of the step's method parameters.
    • setStepParameters

      public void setStepParameters(List<StepInformationLogMessage.StepParameter> stepParameters)
      The list of the step's method parameters.