Tags functionality is not working as expected:No matching tags found
When i use npx cypress run -e TAGS='@LoginScenario' all feature file scenarios are getting executed .
Please let me know any solution for this.
Feature: Google Functionalities
@LoginScenario
Scenario: Verify Login Functionality
Given user navigates to Login page
And user enters valid credentials
Then User is able to login in to application
on Terminal::
npx cypress-tags run 'TAGS=@LoginScenario' --browser chrome
Using cypress.json configuration:
Spec files: {cypress/integration//.{feature,cypress/integration/features}}
*No matching tags found
Any update on this issue ??
Try this command instead:
npx cypress-tags run -e TAGS="@LoginScenario" --browser chrome
I tried the above suggestion, but it does not solve the issue.
It looks like how cypress-tags matches spec files changed.
You need to fix testFiles in cypress.json:
from:
"testFiles": "**/*.{feature,features}",
to something like this:
"testFiles": "**/*.feature",
You can see which spec files are mutched from cypress-tags output,
before the fix:
Spec files: {cypress/integration/**/*.{feature,cypress/integration/features}}
after:
Spec files: cypress/integration/**/*.feature
@antonversal while that solution works if all you have it .feature files it can be solved to use the correct glob by using an array, like so:
"testFiles": ["**/*.{feature,features}"],
This is because the preprocessor will split testfile string on ,, but leave arrays alone.
Using that config the spec files output will work:
Spec files: cypress/integration/**/*.{feature,features}
Most helpful comment
@antonversal while that solution works if all you have it
.featurefiles it can be solved to use the correct glob by using an array, like so:This is because the preprocessor will split testfile string on
,, but leave arrays alone.Using that config the spec files output will work: