Scenario: create Score
....
Scenario: edit Score
....
Scenario: create Team
....
Scenario: edit Team
....
Scenario: create Score
....
Scenario: edit Score
...
Scenario: create Team Score
....
@default
Scenario: create Score
....
@default
Scenario: edit Score
...
@teams
Scenario: create Team Score
....
@default
Scenario: create Team
....
@default
Scenario: edit Team
....
cucumber
BASE_URL=https://mygame.com RESOURCES_DIR=tests/features/resources
tests/features/scores.feature tests/features/teams.feature --tags
@default @teams
cucumber
BASE_URL=https://mygame.com RESOURCES_DIR=tests/features/resources
tests/features/scores.feature tests/features/teams.feature --tags
@default,@teams
--tags @default --tags ~@teams
--tags @teams
We want to do this to help people ensure that there is no order-dependency in their scenarios. It might be worth giving it a try to help flush out these scenarios.
Cheers,
Steve
--
E: st...@boxjump.co.uk
T: +44 7919 337 463
http://tooky.co.uk | http://kickstartacademy.io | https://twitter.com/tooky
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
On 12 Dec 2014, at 21:02, Rob Park <robert...@gmail.com> wrote:
On Fri, Dec 12, 2014 at 10:57 AM, Steve Tooke <st...@boxjump.co.uk> wrote:On 12 Dec 2014, at 15:30, aslak hellesoy <aslak.h...@gmail.com> wrote:On Fri, Dec 12, 2014 at 2:19 PM, Steve Tooke <st...@boxjump.co.uk> wrote:One of the features we are adding in Cucumber 2.0 is the ability to randomise the order that your scenarios are executed.
I guess this is still up for debate, but I personally think Cucumber Ruby 2.0 should offer the ability to *not* randomise the order.If we want users to adopt the idea that independent scenarios is a good thing we need to make randomised ordering the default behaviour. RSpec already does this.Agreed - but I think we should wait for Cucumber-Ruby 2.1 before making it the default. We are trying really hard to make 2.0 a drop in replacement and I guess(?) there are enough order-dependent cucumber suites out there that it could be a surprise.
2 cents:Wouldn't 2.0 be a more appropriate place from a semver perspective to change defaults?And if there's a switch to make it possible that feels similar to rspec changing it's 3.0 formatter with an allowance for rspec-legacy_formatters.
On 12 Dec 2014, at 21:02, Rob Park <robert...@gmail.com> wrote:On Fri, Dec 12, 2014 at 10:57 AM, Steve Tooke <st...@boxjump.co.uk> wrote:On 12 Dec 2014, at 15:30, aslak hellesoy <aslak.h...@gmail.com> wrote:On Fri, Dec 12, 2014 at 2:19 PM, Steve Tooke <st...@boxjump.co.uk> wrote:One of the features we are adding in Cucumber 2.0 is the ability to randomise the order that your scenarios are executed.
I guess this is still up for debate, but I personally think Cucumber Ruby 2.0 should offer the ability to *not* randomise the order.If we want users to adopt the idea that independent scenarios is a good thing we need to make randomised ordering the default behaviour. RSpec already does this.Agreed - but I think we should wait for Cucumber-Ruby 2.1 before making it the default. We are trying really hard to make 2.0 a drop in replacement and I guess(?) there are enough order-dependent cucumber suites out there that it could be a surprise.2 cents:Wouldn't 2.0 be a more appropriate place from a semver perspective to change defaults?And if there's a switch to make it possible that feels similar to rspec changing it's 3.0 formatter with an allowance for rspec-legacy_formatters.Normally I would agree, but there are a couple of problems with doing that here.We want to give people a deprecation warning if they are running specs with no options that default ordering will be changing. With that warning we will need to let them know how they can use the new ordering and check if their features will run with the new. If it doesn’t we will need to let them know how to configure things to keep the current default ordering.
Unfortunately we have no way of providing random ordering on the 1.3.x versions of cucumber.So I think we should introduce the warning in 2.0, and wait until 2.1 to change the ordering. We could wait until 3.0 to make the change? But is this a breaking change, or an update to a default?
Steve
@billing Feature: Verify billing @important Scenario: Missing product description Scenario: Several products
cucumber --tags @billing --tags @important # Runs the first scenario (Scenarios with @important AND @billing) cucumber --tags @billing,@important # Runs both scenarios (Scenarios with @important OR @billing)
@main
Feature: Totals
Scenario: Create Total
...
@teams
Scenario: Create Team Total
...
--tags @default --tags @teams
Agreed - but I think we should wait for Cucumber-Ruby 2.1 before making it the default. We are trying really hard to make 2.0 a drop in replacement and I guess(?) there are enough order-dependent cucumber suites out there that it could be a surprise.Steve
According to the documentation here:
https://github.com/cucumber/cucumber/wiki/Tags@billing Feature: Verify billing @important Scenario: Missing product description Scenario: Several productscucumber --tags @billing --tags @important # Runs the first scenario (Scenarios with @important AND @billing) cucumber --tags @billing,@important # Runs both scenarios (Scenarios with @important OR @billing)and I run:
But this isn't representative of how it really works. If my feature looks like this:
@main
Feature: Totals
Scenario: Create Total
...
@teams
Scenario: Create Team Total
...
--tags @main --tags @teams
It runs BOTH scenarios, not just the LAST one.
So what is the correct behavior? Are the docs wrong?
cucumber BASE_URL=https://mygame.com scores.feature teams.feature results.feature --tags @default ~@teams
cucumber BASE_URL=https://mygame.com scores.feature teams.feature results.feature --tags @default ~@teams --tags @teams
cucumber BASE_URL=https://mygame.com scores.feature teams.feature results.feature --tags @default ~@teams scores.feature teams.feature results.feature --tags @teams
Using the resources, preTeams, postTeams and json_report profiles...
0 scenarios
0 steps
0m0.000s