I have been putting helper methods inside of my own modules and then
including them in RSpec::Story::World, which included in the context
that stories are defined and run in (David, feel free to correct me if
this is not 100% accurate).

module Spec::Story::World
  def foo
     # this is now available to all stories being run
   end
end

Zach

On Mon, Mar 17, 2008 at 9:41 AM, Ashley Moran
<[EMAIL PROTECTED]> wrote:
> On 17/03/2008, Corey Haines <[EMAIL PROTECTED]> wrote:
> >
> > As an interim solution, we added this as helper file in the stories root.
> The key was figuring out what to mixin to.
> >
> > class ActionController::Integration::Session
> >   # ...
> > end
> >
> > -Corey
>
>
> Pretty neat!  Unfortunately I don't think I can do something similar.  I'm
> using the story runner raw to drive selenium, so only have access to the
> RSpec library and nowhere to inject these helper methods.
>
>
> _______________________________________________
>  rspec-users mailing list
>  rspec-users@rubyforge.org
>  http://rubyforge.org/mailman/listinfo/rspec-users
>



-- 
Zach Dennis
http://www.continuousthinking.com
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to