Exception: Expo::Push::TicketsExpectationFailed
- Defined in:
- lib/push/client.rb
Overview
rubocop:disable Style/Documentation
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
Instance Method Summary collapse
-
#initialize(expected_count:, data:) ⇒ TicketsExpectationFailed
constructor
A new instance of TicketsExpectationFailed.
Methods inherited from Error
Constructor Details
#initialize(expected_count:, data:) ⇒ TicketsExpectationFailed
Returns a new instance of TicketsExpectationFailed.
72 73 74 75 76 77 78 79 80 81 82 |
# File 'lib/push/client.rb', line 72 def initialize(expected_count:, data:) self.data = data super format( "Expected %<count>s ticket#{if expected_count != 1 's' end}, actual: %<actual>s. The response data can be inspected.", count: expected_count, actual: data.is_a?(Array) ? data.length : '<not a list of tickets>' ) end |
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data.
70 71 72 |
# File 'lib/push/client.rb', line 70 def data @data end |