Differences between Tables #29

ardavis opened this Issue Nov 2, 2011 · 1 comment


None yet

2 participants

ardavis commented Nov 2, 2011

@dalton and I have just realized that yard-cucumber automatically converts the first item in a table to be a header. However, in many cases, this will not be true.

Using an example similar to the (currently beta) Cucumber Book, you can say things like:

Given my shopping cart contains the following items:
    | cheese  |
    | onion   |
    | sauce   |
    | oranges |

This would cause cheese to be a header in the documentation, when in reality, it's just a list of items.

I cannot come up with a way to distinguish a list of items from a table with a header.

One thought would maybe to examine the step definitions and look if they call 'raw' on the table? That's what I do in order to extract each item from the list, as opposed to having a set of hashes.


burtlo commented Nov 7, 2011

@ardavis I will try and figure out how Cucumber does it and see if I can replicate that in yard-cucumber.

@burtlo burtlo was assigned Nov 7, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment