Displaying 1 result from an estimated 1 matches for "facode".
Did you mean:
facade
2007 Oct 12
3
Strange mock_model behaviour with ActiveResource model
...o models in an app that inherit from ActiveResource::Base.
The scaffold controller tests for one of the models works fine, but
the other one dies when calling mock_model in the "handling GET
/fa_codes" spec:
Specifically, the call to mock model here:
before do
@fa_code = mock_model(FaCode)
FaCode.stub!(:find).and_return([@fa_code])
end
generates this failure:
NameError in ''FaCodesController handling GET /fa_codes should assign
the found fa_codes for the view''
uninitialized constant Spec::Rails::Initializer
(eval):11:in `class''
/home/jhughes/dev/rj/...