[rspec-users] Autotest and subclasses / namespaces

David Chelimsky dchelimsky at gmail.com
Mon Aug 18 09:42:04 EDT 2008

On Mon, Aug 18, 2008 at 8:39 AM, Matt Wynne <matt at mattwynne.net> wrote:
> On 18 Aug 2008, at 14:27, David Chelimsky wrote:
>>> Check out the output from autotest:
>>> /usr/local/bin/ruby -S script/spec -O spec/spec.opts
>>> /Users/matt/Documents/projects/songkick/skweb/app/controllers/admin/cities_controller.rb
>> The fact that autotest is trying to load the controller file itself is
>> probably the source of the problem here.
> I had changed the controller file though (I'm refactoring). Would you expect
> autotest to still just load the corresponding spec, rather than the changed
> controller source file itself?

That's correct. Autotest *should* only load the spec files and they,
in turn, should require anything they need. I'm not saying this is an
autotest bug. It's getting it's direction as to what files to load
when from the mappings set up in rails_rspec.rb and .autotest, so the
bug is likely in there somewhere.

>> I'm sure you noted this earlier, but what version of rspec and zentest
>> are you using?
>>> I'm using ZenTest 3.10.0 / Rails 2.1 / RSpec 1.1.4
>> Have you modified the mappings in rails_rspec.rb (you
>> can do this in RAILS_ROOT/.autotest or ~/.autotest)?
> I do have an ~/.autotest but it's only got Growl stuff in it, and there's
> nothing in my rails root.

K - that shouldn't be the issue.

Why don't you try getting the latest rspec from git and see if the
problem persists.

> cheers,
> Matt
> _______________________________________________
> rspec-users mailing list
> rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users

More information about the rspec-users mailing list