Discussion:
[Cucumber] Is it possible to pass test data using external file like xls or csv in Cucumber Gherkin
Mohammed Chand Kousar Sayed
2018-04-24 11:31:08 UTC
Permalink
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Koen Prins
2018-05-04 08:32:54 UTC
Permalink
Hi Mohammed,

If you mean if there is a Gherkin magic word to import test data into the
test, the answer is no.
What I would recommend is to use a table setup such as the Scenario
Outline, which can be found here:
https://docs.cucumber.io/gherkin/reference/

Gr,
Koen

On Tue, Apr 24, 2018 at 1:31 PM, Mohammed Chand Kousar Sayed <
Post by Mohammed Chand Kousar Sayed
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Tim Walker
2018-05-04 11:44:09 UTC
Permalink
that is what FIT does...
Post by Mohammed Chand Kousar Sayed
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
aslak hellesoy
2018-05-04 22:07:53 UTC
Permalink
No it's not - you'll find numerous threads bout it if you search the forum.

We might add a Gherkin pre-processor one day, that would let include data
from external sources.

Aslak

On Tue, Apr 24, 2018 at 12:31 PM, Mohammed Chand Kousar Sayed <
Post by Mohammed Chand Kousar Sayed
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Wolfgang Hierl
2018-08-25 22:18:28 UTC
Permalink
I have created a maven plugin as pre-processor, which imports csv data in
feature files. It also supports environment specific test data. All details
you can find in Readme.md at
https://bitbucket.org/idensitylab/cucumber-features-pp-maven-plugin/src/master/
Post by Mohammed Chand Kousar Sayed
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
'Michael Cunningham' via Cukes
2018-09-25 11:11:30 UTC
Permalink
Hi Wolfgang,
I'm very interested in your pre-processor. Can you put a link to an
executable jar so I can use it?

Michael
Post by Wolfgang Hierl
I have created a maven plugin as pre-processor, which imports csv data in
feature files. It also supports environment specific test data. All details
you can find in Readme.md at
https://bitbucket.org/idensitylab/cucumber-features-pp-maven-plugin/src/master/
Post by Mohammed Chand Kousar Sayed
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
'Michael Cunningham' via Cukes
2018-09-26 08:49:08 UTC
Permalink
Ps : CucumberFeaturesReplacer.replaceStringInFeature(File feature, File
fOutFile, File csvDir) is missing out.close() after
out.println(replacedContent). Doesn't write contents to file without
close() or flush()

Michael
Post by 'Michael Cunningham' via Cukes
Hi Wolfgang,
I'm very interested in your pre-processor. Can you put a link to an
executable jar so I can use it?
Michael
Post by Wolfgang Hierl
I have created a maven plugin as pre-processor, which imports csv data in
feature files. It also supports environment specific test data. All details
you can find in Readme.md at
https://bitbucket.org/idensitylab/cucumber-features-pp-maven-plugin/src/master/
Post by Mohammed Chand Kousar Sayed
Is it possible to pass test data using external file like xls or csv in
Cucumber Gherkin out of box?
--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...