Running single cucumber tag with maven command line

942 views
Skip to first unread message

abhi

unread,
Mar 22, 2018, 6:28:54 AM3/22/18
to Serenity BDD Users Group
Hi,

I have few Scenarios in feature file i.e. in cucumber feature file and few scenario in java test suite not bdd. (Cucumber+Maven+Serenity)

When I try to run feature file only using below command, it is running feature file scenario first then starts executing java test suite scenario automatically.

Requirement:::I only want to execute feature file with mentioned tag.

"mvn clean verify -Dcucumber.options="--tags @myTag"

Here @Blue is tag in feature file.

Please suggest.

Thanks

John Smart

unread,
Mar 22, 2018, 7:43:17 AM3/22/18
to abhi, Serenity BDD Users Group
This is normal - the cucumber options are processed by Cucumber, and will be ignored by JUnit. You would need to limit the tests run to the cucumber tests, e.g. by using Maven profiles.

--
You received this message because you are subscribed to the Google Groups "Serenity BDD Users Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to thucydides-users+unsubscribe@googlegroups.com.
To post to this group, send email to thucydides-users@googlegroups.com.
Visit this group at https://groups.google.com/group/thucydides-users.
For more options, visit https://groups.google.com/d/optout.



--
___________________________________________________
John Smart | Wakaleo Consulting  |  +44 7398 832273
Making smart teams collaborate better
http://johnfergusonsmart.com  |  john....@wakaleo.com
___________________________________________________

We love breaking down silos and helping smart teams collaborate better! Ask about our tailored on-site workshops in Agile Product Planning, BDD Requirements Discovery,  BDD, TDD and Clean Coding, and Advanced BDD Test Automation.

Need some help with Serenity BDD? Check out our Serenity BDD training and support packages here.
___________________________________________________
Reply all
Reply to author
Forward
0 new messages