Module: HTTParty

Extended by:
HTTParty
Included in:
HTTParty
Defined in:
lib/motion-bundler/mocks/httparty.rb,
lib/motion-bundler/mocks/httparty.rb

Defined Under Namespace

Classes: Response

Instance Method Summary collapse

Instance Method Details

#base_uri(u) ⇒ Object



12
13
14
# File 'lib/motion-bundler/mocks/httparty.rb', line 12

def base_uri(u)
  @base_uri = u.sub(/\/$/, "")
end

#basic_auth(user, password) ⇒ Object



16
17
18
# File 'lib/motion-bundler/mocks/httparty.rb', line 16

def basic_auth(user, password)
  @basic_auth = [user, password]
end

#delete(path, options = {}, &block) ⇒ Object



32
33
34
# File 'lib/motion-bundler/mocks/httparty.rb', line 32

def delete(path, options = {}, &block)
  send_request path, :delete, options, &block
end

#format(f) ⇒ Object



8
9
10
# File 'lib/motion-bundler/mocks/httparty.rb', line 8

def format(f)
  @format = f
end

#get(path, options = {}, &block) ⇒ Object



20
21
22
# File 'lib/motion-bundler/mocks/httparty.rb', line 20

def get(path, options = {}, &block)
  send_request path, :get, options, &block
end

#included(base) ⇒ Object



4
5
6
# File 'lib/motion-bundler/mocks/httparty.rb', line 4

def included(base)
  base.extend self
end

#post(path, options = {}, &block) ⇒ Object



24
25
26
# File 'lib/motion-bundler/mocks/httparty.rb', line 24

def post(path, options = {}, &block)
  send_request path, :post, options, &block
end

#put(path, options = {}, &block) ⇒ Object



28
29
30
# File 'lib/motion-bundler/mocks/httparty.rb', line 28

def put(path, options = {}, &block)
  send_request path, :put, options, &block
end