[rspec-users] Best way to determine if RSpec is loaded?

Ashley Moran ashley.moran at patchspace.co.uk
Tue Sep 30 09:09:36 EDT 2008

On 29 Sep 2008, at 13:28, David Chelimsky wrote:

> In theory it should be fine, but when you're running a suite of
> examples you're going to eventually want to load up everything in the
> app, no?

True!  But I've had a lot of loading issues lately, when autotest runs  
a single file and everything breaks.

>> The one advantage I know of is if the whole app is available, you can
>> mock(My::Class) and it'll tell you if you're mocking something that  
>> doesn't
>> exist.  That's good, right?
> RSpec's mocks don't do that (tell you when a mocked method doesn't
> really exist). Are you using a mocking frawework that does?

Ah, I was referring no the class, not the method.   I like being told  
My::Class doesn't exist, it's a motivation to create the files and write

   it "should do something" do

I find that helps drive development down the app's layers.



More information about the rspec-users mailing list