Re: [rspec-users] Keeping my integration specs DRY..

2011-07-26 Thread David Chelimsky
On Jul 26, 2011, at 12:51 AM, Patrick J. Collins wrote: >> Here's an example of my first test, but I'm wondering how I setup the >> login routine so I can use it in future specs without repeating the >> method. Some sort of - before.each (:login) > You can use shared examples... > > shared_exam

Re: [rspec-users] Keeping my integration specs DRY..

2011-07-25 Thread Patrick J. Collins
> Here's an example of my first test, but I'm wondering how I setup the > login routine so I can use it in future specs without repeating the > method. Some sort of - before.each (:login) You can use shared examples... shared_examples_for "any page requiring authentication" do fill_in :l

Re: [rspec-users] Keeping my integration specs DRY..

2011-07-25 Thread Justin Ko
On Fri, Jul 22, 2011 at 1:50 PM, internetchris wrote: > Hi Group, > > I'm finally taking the time to implement tests in some of my old apps. > I'm using Rails 2.3.5, Rspec 1.3.1, Rspec-rails 1.3.3, and capybara. > > Here's an example of my first test, but I'm wondering how I setup the > login rou