If we are using the JUnit framework to run Cucumber, we need to create a single empty class, as shown:
package steps; import cucumber.api.junit.Cucumber; import org.junit.runner.RunWith; @RunWith(Cucumber.class)
@CucumberOptions(plugin = {"pretty", "html:target/cucumber"})
public class RunCukesTest {
}
With this, we can run the tests in the same way as we run the typical JUnit tests.