Rails2.0 the official support of namespace, making it easier for people with the usual habit of definition Controller For example,We define the following Controller admin/hacks_controller this class namespace is Admin::HackController When we use rspec_autotest for testing,Will be following error no such file to load -- ./spec/views/hacks/../../spec_helper (LoadError)
The wrong reason is very simple. By default, rspec_autotest the loading path and does not take into account the issue of naming space, so it is necessary to be loaded their own. There are two ways: First, edit documents in the corresponding Spec loading path require File.dirname(__FILE__) + '/../../spec_helper' ### here Another, add the overall load require File.expand_path(File.dirname(__FILE__) + "/../spec/spec_helper") Two methods are very useful, but first some trouble.Choose your own ways to use it -- Best Wish For You Raecoo GTalk/Gmail: [EMAIL PROTECTED] MSN: [EMAIL PROTECTED] _______________________________________________ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users