Class ScenarioTestInstance

java.lang.Object
fr.fidorial.testing.ScenarioTestInstance

@Internal public final class ScenarioTestInstance extends Object
A test method annotated with ScenarioTest, as discovered by the runner.
Since:
0.1.0
  • Constructor Details

    • ScenarioTestInstance

      public ScenarioTestInstance(Method method, String group, int timeoutTicks, boolean required)
      Wraps a test method.
      Parameters:
      method - the static method taking a ScenarioTestHelper
      group - the group the test belongs to
      timeoutTicks - the number of ticks after which the test fails
      required - whether a failure fails the whole run
      Since:
      0.1.0
  • Method Details

    • id

      public String id()
      Returns the identifier of the test, <class>/<method>.
      Returns:
      the identifier of the test, <class>/<method>
      Since:
      0.1.0
    • group

      public String group()
      Returns the group the test belongs to.
      Returns:
      the group the test belongs to
      Since:
      0.1.0
    • timeoutTicks

      public int timeoutTicks()
      Returns the number of ticks after which the test fails.
      Returns:
      the number of ticks after which the test fails
      Since:
      0.1.0
    • required

      public boolean required()
      Returns true if a failure fails the whole run.
      Returns:
      true if a failure fails the whole run
      Since:
      0.1.0