Class: Graphiti::SpecHelpers::ErrorsProxy::Error
- Defined in:
- lib/graphiti/spec_helpers/errors_proxy.rb
Instance Attribute Summary collapse
-
#json ⇒ Object
readonly
Returns the value of attribute json.
Instance Method Summary collapse
- #attribute ⇒ Object
-
#code ⇒ Object
TODO: move to top-level code in errorable.
- #detail ⇒ Object
-
#initialize(json) ⇒ Error
constructor
A new instance of Error.
- #message ⇒ Object
- #status ⇒ Object
- #title ⇒ Object
Constructor Details
#initialize(json) ⇒ Error
Returns a new instance of Error.
7 8 9 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 7 def initialize(json) @json = json end |
Instance Attribute Details
#json ⇒ Object (readonly)
Returns the value of attribute json.
5 6 7 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 5 def json @json end |
Instance Method Details
#attribute ⇒ Object
11 12 13 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 11 def attribute @json[:meta][:attribute] end |
#code ⇒ Object
TODO: move to top-level code in errorable
16 17 18 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 16 def code @json[:meta][:code] end |
#detail ⇒ Object
28 29 30 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 28 def detail @json[:detail] end |
#message ⇒ Object
20 21 22 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 20 def @json[:meta][:message] end |
#status ⇒ Object
32 33 34 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 32 def status @json[:status] end |
#title ⇒ Object
24 25 26 |
# File 'lib/graphiti/spec_helpers/errors_proxy.rb', line 24 def title @json[:title] end |