search for: facodescontroller

Displaying 1 result from an estimated 1 matches for "facodescontroller".

2007 Oct 12
3
Strange mock_model behaviour with ActiveResource model
...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/gump_rewrite/vendor/plugins/rspec_on_rails/lib/spec/rails/dsl/behaviour/rails_example.rb:85:in `add_stubs'' /home...