[rspec-devel] [ rspec-Patches-14140 ] fix for TM when switching to alternate file

noreply at rubyforge.org noreply at rubyforge.org
Sun Nov 18 20:10:03 EST 2007


Patches item #14140, was opened at 2007-09-21 21:04
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=3151&aid=14140&group_id=797

Category: RSpec.tmbundle
Group: None
>Status: Closed
Resolution: None
Priority: 3
Submitted By: Trevor Squires (protocool)
Assigned to: David Chelimsky (dchelimsky)
Summary: fix for TM when switching to alternate file

Initial Comment:
When using textmate's ctrl-shift-downarrow (switch to "Alternate File") command I get exceptions of "undefined method + for NilClass".

Note: this *only* happens if the 'alternate file' you are trying to switch to does not exist, and you elect to let TM create it for you.

The problem appears to be down to content_for() incorrectly checking the file_type parameter.  It looks for 'spec' even though it would seem 'model spec' and 'view spec' are examples of the values it receives.

I've attached a patch which corrects this issue for me.

----------------------------------------------------------------------

Comment By: Chad Humphries (spicycode)
Date: 2007-11-19 01:08

Message:
Moved to http://rspec.lighthouseapp.com/projects/5645-rspec/tickets/12-14140-fix-for-tm-when-switching-to-alternate-file#ticket-12-3

----------------------------------------------------------------------

Comment By: David Chelimsky (dchelimsky)
Date: 2007-10-02 22:48

Message:
Please add a spec that fails without this change and passes with it. There are specs in RSpec.tmbundle/Support. You can run them thusly:

cd RSpec.tmbundle/Support
rake spec

They were failing recently due to a bug that I just fixed, so please make sure you've got the most recent trunk.

Thanks.

----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=3151&aid=14140&group_id=797


More information about the rspec-devel mailing list