Module: Adyen::Matchers

Defined in:
lib/adyen/matchers.rb

Defined Under Namespace

Modules: XPathPaymentFormCheck Classes: HaveAdyenPaymentForm

Instance Method Summary (collapse)

Instance Method Details

- (Object) assert_adyen_payment_form(subject, checks = {})



80
81
82
83
# File 'lib/adyen/matchers.rb', line 80

def assert_adyen_payment_form(subject, checks = {})
  default_checks = {:merchant_sig => :anything, :payment_amount => :anything, :currency_code => :anything, :skin_code => :anything }
  assert Adyen::Matchers::XPathPaymentFormCheck.check(subject, default_checks.merge(checks)), 'No Adyen payment form found'
end

- (Object) assert_adyen_recurring_payment_form(subject, checks = {})



85
86
87
88
# File 'lib/adyen/matchers.rb', line 85

def assert_adyen_recurring_payment_form(subject, checks = {})
  recurring_checks = { :recurring => true, :shopper_email => :anything, :shopper_reference => :anything }
  assert_adyen_payment_form(subject, recurring_checks.merge(checks))
end

- (Object) assert_adyen_single_payment_form(subject, checks = {})



90
91
92
93
# File 'lib/adyen/matchers.rb', line 90

def assert_adyen_single_payment_form(subject, checks = {})
  recurring_checks = { :recurring => false }
  assert_adyen_payment_form(subject, recurring_checks.merge(checks))
end

- (Object) have_adyen_payment_form(checks = {})



65
66
67
68
# File 'lib/adyen/matchers.rb', line 65

def have_adyen_payment_form(checks = {})
  default_checks = {:merchant_sig => :anything, :payment_amount => :anything, :currency_code => :anything, :skin_code => :anything }
  HaveAdyenPaymentForm.new(default_checks.merge(checks))
end

- (Object) have_adyen_recurring_payment_form(checks = {})



70
71
72
73
# File 'lib/adyen/matchers.rb', line 70

def have_adyen_recurring_payment_form(checks = {})
  recurring_checks = { :recurring => true, :shopper_email => :anything, :shopper_reference => :anything }
  have_adyen_payment_form(recurring_checks.merge(checks))
end

- (Object) have_adyen_single_payment_form(checks = {})



75
76
77
78
# File 'lib/adyen/matchers.rb', line 75

def have_adyen_single_payment_form(checks = {})
  recurring_checks = { :recurring => false }
  have_adyen_payment_form(recurring_checks.merge(checks))
end