module Warden::Test::WardenHelpers

Public Instance Methods

_on_next_request() click to toggle source

A containter for the #on_next_request items. @api private

# File lib/warden/test/warden_helpers.rb, line 22
def _on_next_request
  @_on_next_request ||= []
  @_on_next_request
end
on_next_request(&blk) click to toggle source

Adds a block to be executed on the next request when the stack reaches warden. The warden proxy is yielded to the block @api public

# File lib/warden/test/warden_helpers.rb, line 9
def on_next_request(&blk)
  _on_next_request << blk
end
test_reset!() click to toggle source

resets wardens tests any blocks queued to execute will be removed @api public

# File lib/warden/test/warden_helpers.rb, line 16
def test_reset!
  _on_next_request.clear
end