[rspec-users] Specs for ApplicationController, where to put them?
win at wincent.com
Thu May 31 01:27:27 EDT 2007
El 31/5/2007, a las 0:51, David Chelimsky escribió:
> On 5/30/07, Wincent Colaiuta <win at wincent.com> wrote:
>> El 30/5/2007, a las 23:11, David Chelimsky escribió:
>>> I think you're spot on about all of this. I'm thinking that a simple
>>> solution would be that each time a shared behaviour is
>>> registered, the
>>> location of its definition can be registered as well. Then we can
>>> ignore the ones defined in the same place when a file gets reloaded,
>>> but still complain when another one is defined with the same name
>>> a different location.
>> Would be great -- it would basically capture the intent of your
>> current implementation -- but how would you get the location of its
> By inspecting caller. We do this already in building up the backtrace.
> I'll pursue this soon.
Ah, of course... I didn't even realize that Kernel#caller was in the
Ruby core... That will definitely work then.
More information about the rspec-users