How to drive data using excel and cucumber

1,951 views
Skip to first unread message

Vishal Kakkar

unread,
Oct 5, 2014, 2:25:27 PM10/5/14
to cu...@googlegroups.com
How to drive data using excel and cucumber. Please advice

Paolo Ambrosio

unread,
Oct 5, 2014, 5:03:15 PM10/5/14
to cu...@googlegroups.com
On Sun, Oct 5, 2014 at 7:25 PM, Vishal Kakkar <vishal....@gmail.com> wrote:

> How to drive data using excel and cucumber. Please advice

If you want scenarios or scenario outline examples to be in a
spreadsheet, I believe Cucumber is not the tool for you.

If instead you want to read an Excel spreadsheet with some data to be
used in a step, you can use any library for the language you are using
to express step definitions (Apache POI for Java, etc.).

Paolo

Vincent Daburon

unread,
Nov 12, 2014, 4:04:57 AM11/12/14
to cu...@googlegroups.com
Hi,

In Cucumber JVM no solution.
But with .Net SpecFlow is possible, look at  :
http://www.specflow.org/plus/excel/getting-started/

with this solution all the scenario is described in Excel not only datas.

Regards.
Vincent D.

Chuck van der Linden

unread,
Nov 24, 2014, 7:41:47 PM11/24/14
to cu...@googlegroups.com
On Sunday, October 5, 2014 11:25:27 AM UTC-7, Vishal Kakkar wrote:
How to drive data using excel and cucumber. Please advice

I would say, Don't.

If cucumber is the right tool for you, you should use scenario outlines and specify the critical values for the scenarios in the examples.  this allows good inspection of the values being tested, expected results, etc instead of 'hiding' that information inside a spreadsheet that cannot be seen by a stakeholder reading the features.

If you are using the spreadsheet as a quick and dirty way of creating 'unused' data like usernames, then consider incorporating that logic inside the step definitions that would create a new user, and incorporate a random value or timestamp to provide uniqueness.

If you are doing something like a combinatorial test based on output from a utility like 'all-pairs' I would not use cucumber as a framework to run that test. 


Reply all
Reply to author
Forward
0 new messages