erran
erran

Reputation: 1320

Cucumber running all tests ignoring "cucumber.yml"

I'm fairly sure I know the root cause (not how to fix it) but background goes as such: I cucumber set up to test features of a project and I use tags in the feature files.

In cucumber.yml:

# config/cucumber.yml
## YAML Template
---
default: --tags ~@wip,~@manual # previously I only used one negative tag in the default profile.
dev: --tags @wip,@manual

Am I right in that the double negative causes all tests to run on the default profile? If so how do I change the default profile to do all tests but ones with either negative tag? If not what is the problem?

Upvotes: 2

Views: 1400

Answers (1)

Prakash Murthy
Prakash Murthy

Reputation: 13067

This thread from the Cucumber mailing list has the answer: https://groups.google.com/forum/?fromgroups=#!topic/cukes/TH-418eRpRQ

As Aslak Hellesoy mentions there, it is 'basic boolean logic' ;-)

Change default: --tags ~@wip,~@manual to default: --tags ~@wip --tags ~@manual to exclude the features with both those tags.

Upvotes: 2

Related Questions