Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

logical AND and OR tags in Cucumber

How we can apply logical AND and OR using tags in Cucumber? I have applied below snippet

@CucumberOptions(plugin = { "pretty" },
features = { "features" },
glue = { "stepdefs" },
tags = { "@SmokeTestCases" })

but I want to apply logical AND and OR in tags How can I do this?

like image 336
Juhi Naik Avatar asked Oct 16 '25 02:10

Juhi Naik


1 Answers

Logically OR you have to use this: For OR logic sapareted with comma(,)

@CucumberOptions(plugin = { "pretty" },
features = { "features" },
glue = { "stepdefs" },
tags = { "@SmokeTestCases,@SanityTestCases" })

Logically AND you have to use this: For AND logic separated with quotes("")

@CucumberOptions(plugin = { "pretty" },
features = { "features" },
glue = { "stepdefs" },
tags = { "@SmokeTestCases","@SanityTestCases" })
like image 162
Yash Patel Avatar answered Oct 18 '25 07:10

Yash Patel



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!