Replies: 1 comment 2 replies
-
If you pass the full table to a step, the table is treated as a parameter and not used as a source for the scenario. Hence you get one scenario with a step that uses a table. Your step implementation is hidden from the scenario, so gauge cannot infer the semantics here. If you need each row to be reported as separate scenario/spec you'll have to use table driven execution. So, to your question:
The short answer is no. Try modelling your scenario to be table driven instead. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am testing Gauge and need to clarify this... Currently i am using tables in 2 ways in my test:
One is like this:
This is my
example.spec
Lançamentos
forget about these asterisks(*) i've put them only to render the markdown, they don't exist in the code
I this first example i am using 2 tables and passing the second one to my step implementation. When i run this spec this is the result:
This is good, mainly because if the first table scenario fails(and only) i get a good separation like this:
Ok, now it is time for the second example
This is my
example.spec
Lançamentos
I'm passing the "full" table as a parameter to my setp with the values that i'll use
In my step i translate the values comming from the markdown to values that my app understand in the function
"transformTableValues"
Right here is where my problems starts. Look to the report:
The whole thing became just one scenario when it is supposed to have 3 scenarios. If i have an error on row 2 the whole scenario will show the error, instead of only row 2...
There is a way to separate the scenarios(rows) when passing a table as a inline argument to a step?
Beta Was this translation helpful? Give feedback.
All reactions