Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Differences between Tables #29

Open
ardavis opened this issue Nov 2, 2011 · 1 comment
Open

Differences between Tables #29

ardavis opened this issue Nov 2, 2011 · 1 comment
Assignees

Comments

@ardavis
Copy link
Contributor

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.

Thoughts?

@burtlo
Copy link
Owner

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants