[rspec-users] Extending RSpec- Best Practices?

Matt Wynne matt at mattwynne.net
Wed May 6 14:15:59 EDT 2009


On 6 May 2009, at 14:52, Nicholas Van Weerdenburg wrote:

> Hi,
>
> I'm reading the RSpec book and it makes references to macros from  
> shoulda and rspec_on_rail_on_crack, but doesn't integrate them,  
> simply describing how to write your own macro. I see there is the  
> "Remarkable" project as well.
>
> After some more googling, I can't make up my mind if I should use  
> these with RSpec or not. As I'm new to them all, I'd like to hear  
> some opinions/experiences in using them with recent versions.
>
> The one knock I've heard regarding macros is that it can slant  
> design to fit the macro's.

I use them quite a bit, and really like them - I factor them out of  
repetitive tests to make little DSLs for testing specific things.

Can you give us a couple of examples of what you're trying to do?

Matt Wynne
http://blog.mattwynne.net
http://www.songkick.com



More information about the rspec-users mailing list