Class: Stall::Payments::FakeGatewayPaymentNotification

Inherits:
Object
  • Object
show all
Defined in:
lib/stall/payments/fake_gateway_payment_notification.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cart) ⇒ FakeGatewayPaymentNotification

Returns a new instance of FakeGatewayPaymentNotification.



6
7
8
# File 'lib/stall/payments/fake_gateway_payment_notification.rb', line 6

def initialize(cart)
  @cart = cart
end

Instance Attribute Details

#cartObject (readonly)

Returns the value of attribute cart.



4
5
6
# File 'lib/stall/payments/fake_gateway_payment_notification.rb', line 4

def cart
  @cart
end

Instance Method Details

#paramsObject



10
11
12
13
# File 'lib/stall/payments/fake_gateway_payment_notification.rb', line 10

def params
  raise 'FakeGatewayPaymentNotification subclasses must define the ' \
        '#params method to return a valid notification params hash.'
end

#raw_postObject



15
16
17
# File 'lib/stall/payments/fake_gateway_payment_notification.rb', line 15

def raw_post
  params.to_query
end