Hi This was bugging the hell out of me until I found a fix just. I have been getting reams and reams of errors from reference to one model class in a controller spec. Here's one of the 57 that go wrong:
20) LoadError in 'UsersController PUT /users/:id when the model is invalid and there is no primary user issue and the user clicked Save should not assign the primary user issue to the view' Expected /Users/ashleymoran/Documents/TechnoPhobia/becta/apps/Backend/ app/models/user_state.rb to define UserState ./spec/controllers/users_controller_spec.rb:343: script/spec:4: But the weird thing is it ONLY happens when you run the spec in isolation. As part of a full autotest run, it's fine. The fix is to put this at the top of the controller file: require_dependency "user_state" Any idea what could be going wrong? It's not the first class loader issue I've hit, when I see a pattern I'll file a ticket. Just wondered if this was new to everyone here. Ashley -- http://www.patchspace.co.uk/ http://aviewfromafar.net/ _______________________________________________ rspec-users mailing list [email protected] http://rubyforge.org/mailman/listinfo/rspec-users
