Can we call one scenario inside another scenario in cucumber? -


i started working behavior driven tool cucumber. fun tool use. while working on problem. came across of time, not reusing code.

that's why want call scenario scenario. have searched found nothing helpful. can ?

another same question posted here on github

this may you're looking for: https://github.com/cucumber/cucumber/wiki/calling-steps-from-step-definitions

so there couple of things can do. if have step want reuse following:

given /^i log in (.*)$/ |name|   # ... end 

you can call within step so:

given /^(.*) logged in$/ |name|   step "i log in #{name}" end 

you can following within step definition:

steps %q{     given log in #{name}   } 

Comments

Popular posts from this blog

sql - invalid in the select list because it is not contained in either an aggregate function -

Angularjs unit testing - ng-disabled not working when adding text to textarea -

How to start daemon on android by adb -