None of the features at [src/main/java/apitest/feature] matched the filters: [@ApiTest]

Open 0 Answers 19 Views

I have created a JUnit class with Cucumber annotations like this:

@CucumberOptions(features = {"src/main/java/apitest/feature/APIAuthentication"},
format = {"json:target/cucumber.json", "html:target/site/cucumber-pretty"},
glue = "apitest/steps",
plugin = {"pretty","html:reports/test-report"},
tags = {"@ApiTest"})
public class Runner extends AbstractTestNGCucumberTests{

Now src/main/java/apitest/feature contains 1-test case so 1-feature, so if 10 -test case then 10 -features
if i give src/main/java/apitest/feature in features = {"src/main/java/apitest/feature"} it is not picking the all the feature with its corresponding step

it says : None of the features at [src/main/java/apitest/feature] matched the filters: [@ApiTest]
0 Scenarios
0 Steps

Here is my .feature file:

In order to test the REST API TESTING
Scenario: To test the Login functionality
Given User provides the credentials username and password to authenticate
When The user gets logged in assert the status code as 302
Then get the session id created for further usage

Kindly advise.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.