[rspec-users] Including matchers in Cucumber

2008-09-22 Thread Ashley Moran
Hi Where do you include matcher modules in Cucumber so they don't pollute Object? ie so module TwitterMatchers class HaveUserStatus # ... end def have_user_status(user, status) HaveUserStatus.new(user, status) end end is only visible in Then it should

Re: [rspec-users] Including matchers in Cucumber

2008-09-22 Thread aslak hellesoy
On Mon, Sep 22, 2008 at 1:21 PM, Ashley Moran [EMAIL PROTECTED] wrote: Hi Where do you include matcher modules in Cucumber so they don't pollute Object? ie so module TwitterMatchers class HaveUserStatus # ... end def have_user_status(user, status)

Re: [rspec-users] Including matchers in Cucumber

2008-09-22 Thread Ashley Moran
On Sep 22, 2008, at 12:30 pm, aslak hellesoy wrote: # Put this in steps/env.rb World do w = Object.new w.extend(TwitterMatchers) w end Aslak Cool! I did it like this in the end, when I figured out what it was doing: class MyWorld include TwitterMatchers end World do