Class: PayjpMock::Response::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/payjp_mock/response/base.rb

Direct Known Subclasses

Deleted, Error::Base, List, Resource::Base

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#attributesObject (readonly)

Returns the value of attribute attributes.



2
3
4
# File 'lib/payjp_mock/response/base.rb', line 2

def attributes
  @attributes
end

Instance Method Details

#bodyObject



4
5
6
# File 'lib/payjp_mock/response/base.rb', line 4

def body
  @attributes.to_json
end

#exceptionObject



12
13
14
# File 'lib/payjp_mock/response/base.rb', line 12

def exception
  nil
end

#statusObject

Raises:

  • (NotImplementedError)


8
9
10
# File 'lib/payjp_mock/response/base.rb', line 8

def status
  raise NotImplementedError
end

#to_hObject



16
17
18
# File 'lib/payjp_mock/response/base.rb', line 16

def to_h
  @attributes
end