ttutisani/Xunit.Gherkin.Quick

Scenarion Outline does not follow Gherkin Guidelines

AlexTeixeira opened this issue · 4 comments

Hi,

From what I can read from Gherkin document a scenario outline with examples should run one test for each rows :

https://cucumber.io/docs/gherkin/reference/#scenario-outline

Currently, the implementation only run the last row of the examples.
This is a problem because scenario output with examples have no longer interest.

Hi @AlexTeixeira

Can you please provide an example of the issue?
Xunit.Gherkin.Quick does follow the principle that you expect - it runs a scenario for each example row.
Everything is described here: https://github.com/ttutisani/Xunit.Gherkin.Quick/blob/master/docs/scenario-outline.md

Please try to follow the example from the link that I posted and see if it works. If it works and your concrete outline does not work, I would like to see what you have to investigate.

Thank you!

Hi,

After implementing the example, All seems to works good with the dotnet test command.

But in rider, the visual runner only find 1 tests and run the last one.
In Visual Studio for mac the test run and display correctly.

I post both screen to highligh differences

image

image

All right, that explains what you meant.

I don't know how Rider's runner works, but it may not honor the Xunit's way of execution. In that case, I cannot do much about it. dotnet test command uses Xunit runner and everything will work as expected. Xunit.Gherkin.Quick is built on top of Xunit's test executors.

By looking at the screenshots, I think the Rider executes the first test (#1) and not the last. Is there a way to configure Rider to use the Xunit runner? I am only guessing as I have never used Rider myself.

Yes,

Rider has some good features, but seems that this one is not ^^.

Yes, I am using dotnet test command as a workaround for now.
I will try to configure Xunit and ask in the rider forum. If I found something, I share the answer here for the other Rider users.

For info, when I debug or check the acceptance result, the runner use the last "row" of the example.

I close the thread. Thanks for your quick answer :)