Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cucumber: Automatic step file creation?

When i run cucumber it displays the possible steps that i should define, an example from the RSpec book:

1 scenario (1 undefined)
4 steps (4 undefined)
0m0.001s
You can implement step definitions for undefined steps with these snippets:
Given /^I am not yet playing$/ do
  pending
end
When /^I start a new game$/ do
  pending
end
Then /^the game should say “Welcome to CodeBreaker”$/ do
  pending
end
Then /^the game should say “Enter guess:”$/ do
  pending
end

Is there a way that it will automaticly create the step definitions file, so i don't have to rewrite or copy paste by hand but i can just to customize them to be more generic?

like image 235
Jakub Troszok Avatar asked Dec 30 '22 19:12

Jakub Troszok


1 Answers

Cucumber doesn't offer this feature. Probably because you would have to tell it where to put the step definitions file, and what to name it.

like image 181
kevinrutherford Avatar answered Jan 27 '23 15:01

kevinrutherford