Module: HttpStub::Server::StubResponse

Defined in:
lib/http_stub/server/stub_response.rb,
lib/http_stub/server/stub_response/base.rb,
lib/http_stub/server/stub_response/file.rb,
lib/http_stub/server/stub_response/text.rb

Defined Under Namespace

Classes: Base, File, Text

Class Method Summary collapse

Class Method Details

.create(args) ⇒ Object



6
7
8
9
# File 'lib/http_stub/server/stub_response.rb', line 6

def self.create(args)
  args["body"].is_a?(Hash) ?
    HttpStub::Server::StubResponse::File.new(args) : HttpStub::Server::StubResponse::Text.new(args)
end