Module: Testify::Middleware

Includes:
Aliasable
Defined in:
lib/middleware.rb

Instance Method Summary collapse

Instance Method Details

#call(env) ⇒ Object

By default, the middleware base class just calls the next app on the stack - you will almost certainly want to override this method.


16
17
18
# File 'lib/middleware.rb', line 16

def call(env)
  @app.call(env)
end

#initialize(app) ⇒ Object

By default, Testify middleware is initialized with only the next app on the stack. If you override this in a way that changes the signature, you may also need to override Runner.construct_app_stack.


9
10
11
# File 'lib/middleware.rb', line 9

def initialize(app)
  @app = app
end