io.cucumber.plugin.event.TestStepStarted Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cucumber-plugin Show documentation
Show all versions of cucumber-plugin Show documentation
Plugin interface for Cucumber-JVM
The newest version!
package io.cucumber.plugin.event;
import org.apiguardian.api.API;
import java.time.Instant;
import java.util.Objects;
/**
* A test step started event is broadcast when ever a step starts.
*
* A step can either be a {@link PickleStepTestStep} or a {@link HookTestStep}
* depending on what step was executed.
*
* Each test step started event is followed by an matching
* {@link TestStepFinished} event for the same step.The order in which these
* events may be expected is:
*
*
* [before hook,]* [[before step hook,]* test step, [after step hook,]*]+, [after hook,]*
*
*
* @see PickleStepTestStep
* @see HookTestStep
*/
@API(status = API.Status.STABLE)
public final class TestStepStarted extends TestCaseEvent {
private final TestStep testStep;
public TestStepStarted(Instant timeInstant, TestCase testCase, TestStep testStep) {
super(timeInstant, testCase);
this.testStep = Objects.requireNonNull(testStep);
}
public TestStep getTestStep() {
return testStep;
}
}