[rspec-users] DRYing up stories

Neil M. Young ermok at tiscali.co.uk
Wed Jan 23 16:45:14 EST 2008


I'm finding that I'm writing sets of very similar scenarios to check access
permissions for each of my actions. Does anyone have suggestions on how to
dry this up:

Given an existing Account
And a logged in Admin
When the user visits account/manage
Then he should get access

Given an existing Account
And a logged in Manager
When the user visits account/manage
Then he should get access

Given an existing Account
And a logged in Supervisor
When the user visits account/manage
Then he should not get access

Given an existing Account
And a logged in Reviewer
When the user visits account/manage
Then he should not get access

Given an existing Account
And a logged in User
When the user visits account/manage
Then he should not get access

-- 
View this message in context: http://www.nabble.com/DRYing-up-stories-tp15053384p15053384.html
Sent from the rspec-users mailing list archive at Nabble.com.



More information about the rspec-users mailing list