Re: [rspec-users] Problem with view spec - works inside the browser but spec fails with nil object

2007-11-11 Thread Hans de Graaff
You are trying to test a lot of things at the same time, which is one of the reasons that it is now hard to diagnose a problem. I would tackle this by a) writing a separate spec for the partial _question_for_candidate b) write a separate spec for the helper that renders the question b) in the

Re: [rspec-users] Problem with view spec - works inside the browser but spec fails with nil object

2007-11-11 Thread Caio Moritz Ronchi
Hi Hans, I rewrote my specs the way you suggested and now everything works! For those who are interested, here's how the code looks like now (after following Hans' tips). a) writing a separate spec for the partial _question_for_candidate require File.dirname(__FILE__) + '/../../spec_helper'