Parent

Methods

Class Index [+]

Quicksearch

Merb::Test::RequestHelper::FakeRequest

FakeRequest sets up a default enviroment which can be overridden either by passing and env into initialize or using request[‘HTTP_VAR’] = ‘foo’

Constants

DEFAULT_ENV

Public Class Methods

new(env = {}, req = StringIO.new) click to toggle source

Parameters

env

Environment options that override the defaults.

req

The request to set as input for Rack.

    # File lib/merb-core/test/helpers/mock_request_helper.rb, line 13
13:         def initialize(env = {}, req = StringIO.new)
14:           env.environmentize_keys!
15:           env['rack.input'] = req
16:           @start       = Time.now
17:           super(DEFAULT_ENV.merge(env))
18:         end
new(env = {}, req = StringIO.new) click to toggle source
    # File lib/merb-core/test/helpers/mock_request_helper.rb, line 20
20:         def self.new(env = {}, req = StringIO.new)
21:           super
22:         end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.