activemerchant 1.2.1 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data.tar.gz.sig +0 -0
- data/CHANGELOG +310 -294
- data/CONTRIBUTERS +13 -0
- data/README +55 -31
- data/Rakefile +21 -13
- data/lib/active_merchant.rb +7 -0
- data/lib/active_merchant/billing/avs_result.rb +95 -0
- data/lib/active_merchant/billing/base.rb +8 -3
- data/lib/active_merchant/billing/check.rb +61 -0
- data/lib/active_merchant/billing/credit_card.rb +104 -80
- data/lib/active_merchant/billing/credit_card_formatting.rb +11 -8
- data/lib/active_merchant/billing/credit_card_methods.rb +76 -32
- data/lib/active_merchant/billing/cvv_result.rb +38 -0
- data/lib/active_merchant/billing/expiry_date.rb +28 -0
- data/lib/active_merchant/billing/gateway.rb +47 -111
- data/lib/active_merchant/billing/gateways/authorize_net.rb +508 -121
- data/lib/active_merchant/billing/gateways/bogus.rb +26 -32
- data/lib/active_merchant/billing/gateways/brain_tree.rb +82 -70
- data/lib/active_merchant/billing/gateways/card_stream.rb +43 -15
- data/lib/active_merchant/billing/gateways/cyber_source.rb +9 -29
- data/lib/active_merchant/billing/gateways/data_cash.rb +18 -38
- data/lib/active_merchant/billing/gateways/efsnet.rb +23 -50
- data/lib/active_merchant/billing/gateways/eway.rb +8 -19
- data/lib/active_merchant/billing/gateways/exact.rb +17 -25
- data/lib/active_merchant/billing/gateways/linkpoint.rb +18 -25
- data/lib/active_merchant/billing/gateways/moneris.rb +9 -39
- data/lib/active_merchant/billing/gateways/net_registry.rb +113 -182
- data/lib/active_merchant/billing/gateways/netbilling.rb +168 -0
- data/lib/active_merchant/billing/gateways/pay_junction.rb +52 -73
- data/lib/active_merchant/billing/gateways/pay_secure.rb +120 -0
- data/lib/active_merchant/billing/gateways/payflow.rb +13 -14
- data/lib/active_merchant/billing/gateways/payflow/payflow_common_api.rb +55 -37
- data/lib/active_merchant/billing/gateways/payflow/payflow_response.rb +4 -0
- data/lib/active_merchant/billing/gateways/payflow_express.rb +2 -4
- data/lib/active_merchant/billing/gateways/payment_express.rb +11 -30
- data/lib/active_merchant/billing/gateways/paypal.rb +3 -14
- data/lib/active_merchant/billing/gateways/paypal/paypal_common_api.rb +36 -16
- data/lib/active_merchant/billing/gateways/paypal_express.rb +1 -2
- data/lib/active_merchant/billing/gateways/plugnpay.rb +7 -15
- data/lib/active_merchant/billing/gateways/protx.rb +24 -25
- data/lib/active_merchant/billing/gateways/psigate.rb +34 -71
- data/lib/active_merchant/billing/gateways/psl_card.rb +24 -19
- data/lib/active_merchant/billing/gateways/quickpay.rb +10 -24
- data/lib/active_merchant/billing/gateways/realex.rb +7 -19
- data/lib/active_merchant/billing/gateways/secure_pay_tech.rb +113 -0
- data/lib/active_merchant/billing/gateways/skip_jack.rb +437 -0
- data/lib/active_merchant/billing/gateways/trans_first.rb +5 -14
- data/lib/active_merchant/billing/gateways/trust_commerce.rb +100 -39
- data/lib/active_merchant/billing/gateways/usa_epay.rb +60 -55
- data/lib/active_merchant/billing/gateways/verifi.rb +32 -39
- data/lib/active_merchant/billing/gateways/viaklix.rb +31 -37
- data/lib/active_merchant/billing/integrations.rb +2 -0
- data/lib/active_merchant/billing/integrations/bogus.rb +5 -0
- data/lib/active_merchant/billing/integrations/bogus/return.rb +10 -0
- data/lib/active_merchant/billing/integrations/chronopay.rb +5 -0
- data/lib/active_merchant/billing/integrations/chronopay/return.rb +10 -0
- data/lib/active_merchant/billing/integrations/gestpay.rb +5 -0
- data/lib/active_merchant/billing/integrations/gestpay/return.rb +10 -0
- data/lib/active_merchant/billing/integrations/hi_trust.rb +26 -0
- data/lib/active_merchant/billing/integrations/hi_trust/helper.rb +58 -0
- data/lib/active_merchant/billing/integrations/hi_trust/notification.rb +57 -0
- data/lib/active_merchant/billing/integrations/hi_trust/return.rb +67 -0
- data/lib/active_merchant/billing/integrations/nochex.rb +5 -0
- data/lib/active_merchant/billing/integrations/nochex/return.rb +10 -0
- data/lib/active_merchant/billing/integrations/paypal.rb +5 -0
- data/lib/active_merchant/billing/integrations/paypal/return.rb +10 -0
- data/lib/active_merchant/billing/integrations/return.rb +35 -0
- data/lib/active_merchant/billing/integrations/two_checkout.rb +5 -0
- data/lib/active_merchant/billing/integrations/two_checkout/return.rb +17 -0
- data/lib/active_merchant/billing/response.rb +12 -8
- data/lib/active_merchant/lib/posts_data.rb +39 -7
- data/lib/active_merchant/lib/requires_parameters.rb +2 -3
- data/lib/active_merchant/lib/utils.rb +18 -0
- data/lib/active_merchant/lib/validateable.rb +3 -3
- data/lib/support/gateway_support.rb +22 -9
- data/script/destroy +14 -0
- data/script/generate +7 -7
- data/test/fixtures.yml +25 -3
- data/test/remote/gateways/remote_authorize_net_test.rb +145 -0
- data/test/remote/gateways/remote_brain_tree_test.rb +118 -0
- data/test/{remote_tests → remote/gateways}/remote_card_stream_test.rb +56 -68
- data/test/{remote_tests → remote/gateways}/remote_cyber_source_test.rb +21 -32
- data/test/{remote_tests → remote/gateways}/remote_data_cash_test.rb +2 -2
- data/test/{remote_tests → remote/gateways}/remote_efsnet_test.rb +22 -34
- data/test/{remote_tests → remote/gateways}/remote_eway_test.rb +18 -15
- data/test/{remote_tests → remote/gateways}/remote_exact_test.rb +20 -19
- data/test/{remote_tests → remote/gateways}/remote_linkpoint_test.rb +31 -63
- data/test/remote/gateways/remote_moneris_test.rb +82 -0
- data/test/{remote_tests → remote/gateways}/remote_net_registry_test.rb +19 -54
- data/test/remote/gateways/remote_netbilling_test.rb +70 -0
- data/test/{remote_tests → remote/gateways}/remote_pay_junction_test.rb +41 -60
- data/test/remote/gateways/remote_pay_secure_test.rb +39 -0
- data/test/{remote_tests → remote/gateways}/remote_payflow_express_test.rb +2 -2
- data/test/{remote_tests → remote/gateways}/remote_payflow_test.rb +34 -38
- data/test/{remote_tests → remote/gateways}/remote_payflow_uk_test.rb +13 -12
- data/test/{remote_tests → remote/gateways}/remote_payment_express_test.rb +26 -36
- data/test/{remote_tests → remote/gateways}/remote_paypal_express_test.rb +3 -3
- data/test/{remote_tests → remote/gateways}/remote_paypal_test.rb +25 -21
- data/test/{remote_tests → remote/gateways}/remote_plugnpay_test.rb +18 -16
- data/test/{remote_tests → remote/gateways}/remote_protx_test.rb +33 -33
- data/test/remote/gateways/remote_psigate_test.rb +50 -0
- data/test/{remote_tests → remote/gateways}/remote_psl_card_test.rb +27 -26
- data/test/{remote_tests → remote/gateways}/remote_quickpay_test.rb +48 -48
- data/test/{remote_tests → remote/gateways}/remote_realex_test.rb +30 -33
- data/test/remote/gateways/remote_secure_pay_tech_test.rb +37 -0
- data/test/remote/gateways/remote_secure_pay_test.rb +28 -0
- data/test/remote/gateways/remote_skipjack_test.rb +105 -0
- data/test/{remote_tests → remote/gateways}/remote_trans_first_test.rb +7 -10
- data/test/remote/gateways/remote_trust_commerce_test.rb +152 -0
- data/test/{remote_tests → remote/gateways}/remote_usa_epay_test.rb +11 -22
- data/test/{remote_tests → remote/gateways}/remote_verifi_test.rb +27 -27
- data/test/{remote_tests → remote/gateways}/remote_viaklix_test.rb +8 -18
- data/test/{remote_tests → remote/integrations}/remote_gestpay_integration_test.rb +1 -1
- data/test/{remote_tests → remote/integrations}/remote_paypal_integration_test.rb +1 -1
- data/test/test_helper.rb +102 -61
- data/test/unit/avs_result_test.rb +59 -0
- data/test/unit/base_test.rb +33 -39
- data/test/unit/check_test.rb +76 -0
- data/test/unit/credit_card_formatting_test.rb +10 -15
- data/test/unit/credit_card_methods_test.rb +132 -17
- data/test/unit/credit_card_test.rb +157 -228
- data/test/unit/cvv_result_test.rb +33 -0
- data/test/unit/expiry_date_test.rb +21 -0
- data/test/unit/gateways/authorize_net_test.rb +180 -40
- data/test/unit/gateways/bogus_test.rb +2 -3
- data/test/unit/gateways/brain_tree_test.rb +63 -29
- data/test/unit/gateways/card_stream_test.rb +59 -6
- data/test/unit/gateways/cyber_source_test.rb +59 -40
- data/test/unit/gateways/data_cash_test.rb +82 -1
- data/test/unit/gateways/efsnet_test.rb +97 -44
- data/test/unit/gateways/eway_test.rb +55 -42
- data/test/unit/gateways/exact_test.rb +93 -55
- data/test/unit/gateways/gateway_test.rb +7 -0
- data/test/unit/gateways/linkpoint_test.rb +60 -58
- data/test/unit/gateways/moneris_test.rb +67 -76
- data/test/unit/gateways/net_registry_test.rb +351 -419
- data/test/unit/gateways/netbilling_test.rb +54 -0
- data/test/unit/gateways/pay_junction_test.rb +108 -46
- data/test/unit/gateways/pay_secure_test.rb +71 -0
- data/test/unit/gateways/payflow_express_test.rb +0 -8
- data/test/unit/gateways/payflow_test.rb +136 -65
- data/test/unit/gateways/payflow_uk_test.rb +0 -38
- data/test/unit/gateways/payment_express_test.rb +31 -51
- data/test/unit/gateways/paypal_express_test.rb +8 -2
- data/test/unit/gateways/paypal_test.rb +213 -54
- data/test/unit/gateways/plugnpay_test.rb +39 -32
- data/test/unit/gateways/protx_test.rb +45 -33
- data/test/unit/gateways/psigate_test.rb +146 -87
- data/test/unit/gateways/psl_card_test.rb +37 -24
- data/test/unit/gateways/quickpay_test.rb +33 -46
- data/test/unit/gateways/realex_test.rb +32 -31
- data/test/unit/gateways/secure_pay_tech_test.rb +44 -0
- data/test/unit/gateways/secure_pay_test.rb +35 -26
- data/test/unit/gateways/skip_jack_test.rb +125 -0
- data/test/unit/gateways/trans_first_test.rb +24 -37
- data/test/unit/gateways/trust_commerce_test.rb +47 -26
- data/test/unit/gateways/usa_epay_test.rb +52 -41
- data/test/unit/gateways/verifi_test.rb +41 -35
- data/test/unit/gateways/viaklix_test.rb +38 -32
- data/test/unit/generators/test_gateway_generator.rb +46 -0
- data/test/unit/generators/test_generator_helper.rb +20 -0
- data/test/unit/generators/test_integration_generator.rb +53 -0
- data/test/unit/integrations/action_view_helper_test.rb +7 -14
- data/test/unit/integrations/bogus_module_test.rb +4 -0
- data/test/unit/integrations/chronopay_module_test.rb +4 -0
- data/test/unit/integrations/gestpay_module_test.rb +4 -0
- data/test/unit/integrations/helpers/hi_trust_helper_test.rb +16 -0
- data/test/unit/integrations/hi_trust_module_test.rb +13 -0
- data/test/unit/integrations/nochex_module_test.rb +4 -0
- data/test/unit/integrations/notifications/hi_trust_notification_test.rb +38 -0
- data/test/unit/integrations/paypal_module_test.rb +4 -0
- data/test/unit/integrations/returns/chronopay_return_test.rb +11 -0
- data/test/unit/integrations/returns/gestpay_return_test.rb +10 -0
- data/test/unit/integrations/returns/hi_trust_return_test.rb +24 -0
- data/test/unit/integrations/returns/nochex_return_test.rb +10 -0
- data/test/unit/integrations/returns/paypal_return_test.rb +10 -0
- data/test/unit/integrations/returns/return_test.rb +11 -0
- data/test/unit/integrations/returns/two_checkout_return_test.rb +24 -0
- data/test/unit/integrations/two_checkout_module_test.rb +4 -0
- data/test/unit/posts_data_test.rb +86 -0
- data/test/unit/response_test.rb +15 -1
- data/test/unit/utils_test.rb +7 -0
- data/test/unit/validateable_test.rb +10 -6
- metadata +180 -142
- metadata.gz.sig +0 -0
- data/lib/active_merchant/billing/gateways/paypal/api_cert_chain.crt +0 -35
- data/script/generator/base.rb +0 -45
- data/script/generator/generator.rb +0 -24
- data/script/generator/generators/gateway/gateway_generator.rb +0 -14
- data/script/generator/generators/gateway/templates/gateway.rb +0 -73
- data/script/generator/generators/gateway/templates/gateway_test.rb +0 -41
- data/script/generator/generators/gateway/templates/remote_gateway_test.rb +0 -56
- data/script/generator/generators/integration/integration_generator.rb +0 -25
- data/script/generator/generators/integration/templates/helper.rb +0 -34
- data/script/generator/generators/integration/templates/helper_test.rb +0 -54
- data/script/generator/generators/integration/templates/integration.rb +0 -18
- data/script/generator/generators/integration/templates/module_test.rb +0 -9
- data/script/generator/generators/integration/templates/notification.rb +0 -100
- data/script/generator/generators/integration/templates/notification_test.rb +0 -41
- data/script/generator/manifest.rb +0 -20
- data/test/remote_tests/remote_authorize_net_test.rb +0 -113
- data/test/remote_tests/remote_brain_tree_test.rb +0 -78
- data/test/remote_tests/remote_moneris_test.rb +0 -110
- data/test/remote_tests/remote_psigate_test.rb +0 -87
- data/test/remote_tests/remote_secure_pay_test.rb +0 -36
- data/test/remote_tests/remote_trust_commerce_test.rb +0 -136
|
@@ -6,4 +6,8 @@ class ChronopayModuleTest < Test::Unit::TestCase
|
|
|
6
6
|
def test_notification_method
|
|
7
7
|
assert_instance_of Nochex::Notification, Nochex.notification('name=cody')
|
|
8
8
|
end
|
|
9
|
+
|
|
10
|
+
def test_return_method
|
|
11
|
+
assert_instance_of Nochex::Return, Nochex.return('name=cody')
|
|
12
|
+
end
|
|
9
13
|
end
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
require File.dirname(__FILE__) + '/../../../test_helper'
|
|
2
|
+
|
|
3
|
+
class HiTrustNotificationTest < Test::Unit::TestCase
|
|
4
|
+
include ActiveMerchant::Billing::Integrations
|
|
5
|
+
|
|
6
|
+
def setup
|
|
7
|
+
@notification = HiTrust::Notification.new(successful_response)
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
def test_accessors
|
|
11
|
+
assert @notification.complete?
|
|
12
|
+
assert_equal "Completed", @notification.status
|
|
13
|
+
assert_equal "012345678901", @notification.transaction_id
|
|
14
|
+
assert_equal "1000", @notification.item_id
|
|
15
|
+
assert_equal "101010", @notification.account
|
|
16
|
+
assert_equal "500", @notification.gross
|
|
17
|
+
assert_equal "USD", @notification.currency
|
|
18
|
+
assert_equal Time.parse("2007-12-01.12.35.40.123456"), @notification.received_at
|
|
19
|
+
assert @notification.test?
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def test_compositions
|
|
23
|
+
assert_equal Money.new(500, 'USD'), @notification.amount
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def test_send_acknowledgement
|
|
27
|
+
assert @notification.acknowledge
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def test_respond_to_acknowledge
|
|
31
|
+
assert @notification.respond_to?(:acknowledge)
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
private
|
|
35
|
+
def successful_response
|
|
36
|
+
'retcode=00&ordernumber=1000&orderstatus=02&authCode=123456&eci=VISA3D&authRRN=012345678901&storeid=101010&approveamount=500¤cy=USD&orderdate=2007-12-01.12.35.40.123456'
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -21,4 +21,8 @@ class PaypalModuleTest < Test::Unit::TestCase
|
|
|
21
21
|
ActiveMerchant::Billing::Base.integration_mode = :zoomin
|
|
22
22
|
assert_raise(StandardError){ Paypal.service_url }
|
|
23
23
|
end
|
|
24
|
+
|
|
25
|
+
def test_return_method
|
|
26
|
+
assert_instance_of Paypal::Return, Paypal.return('name=cody')
|
|
27
|
+
end
|
|
24
28
|
end
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
require File.dirname(__FILE__) + '/../../../test_helper'
|
|
2
|
+
|
|
3
|
+
class HiTrustReturnTest < Test::Unit::TestCase
|
|
4
|
+
include ActiveMerchant::Billing::Integrations
|
|
5
|
+
|
|
6
|
+
def test_successful_return
|
|
7
|
+
r = HiTrust::Return.new('order_id=&mscssid=&retcode=00&ordernumber=1138742&type=Auth')
|
|
8
|
+
assert r.success?
|
|
9
|
+
assert_equal HiTrust::Return::SUCCESS, r.params['retcode']
|
|
10
|
+
assert_equal HiTrust::Return::CODES[HiTrust::Return::SUCCESS], r.message
|
|
11
|
+
end
|
|
12
|
+
|
|
13
|
+
def test_failed_return
|
|
14
|
+
r = HiTrust::Return.new('retcode=-100')
|
|
15
|
+
assert_false r.success?
|
|
16
|
+
assert_equal HiTrust::Return::CODES['-100'], r.message
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
def test_unknown_return
|
|
20
|
+
r = HiTrust::Return.new('retcode=unknown')
|
|
21
|
+
assert_false r.success?
|
|
22
|
+
assert_nil r.message
|
|
23
|
+
end
|
|
24
|
+
end
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
require File.dirname(__FILE__) + '/../../../test_helper'
|
|
2
|
+
|
|
3
|
+
class TwoCheckoutReturnTest < Test::Unit::TestCase
|
|
4
|
+
include ActiveMerchant::Billing::Integrations
|
|
5
|
+
|
|
6
|
+
def test_successful_purchase
|
|
7
|
+
r = TwoCheckout::Return.new(successful_purchase)
|
|
8
|
+
assert r.success?
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
def test_pending_purchase
|
|
12
|
+
r = TwoCheckout::Return.new(failed_purchase)
|
|
13
|
+
assert !r.success?
|
|
14
|
+
end
|
|
15
|
+
|
|
16
|
+
private
|
|
17
|
+
def successful_purchase
|
|
18
|
+
'sid=1232919&fixed=Y&key=C17C887BDCCD0499264FAE9F578CCA66&state=ON&email=codyfauser%40gmail.com&street_address=138+Clarence+St.&city=Ottawa&cart_order_id=9&order_number=3860340141&merchant_order_id=%231009&country=CAN&ip_country=&cart_id=9&lang=en&demo=Y&pay_method=CC&total=118.30&phone=%28613%29555-5555+&credit_card_processed=Y&zip=K1N5P8&street_address2=Apartment+1&card_holder_name=Cody++Fauser'
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def failed_purchase
|
|
22
|
+
'sid=1232919&fixed=Y&key=C17C887BDCCD0499264FAE9F578CCA66&state=ON&email=codyfauser%40gmail.com&street_address=138+Clarence+St.&city=Ottawa&cart_order_id=9&order_number=3860340141&merchant_order_id=%231009&country=CAN&ip_country=&cart_id=9&lang=en&demo=Y&pay_method=CC&total=118.30&phone=%28613%29555-5555+&credit_card_processed=K&zip=K1N5P8&street_address2=Apartment+1&card_holder_name=Cody++Fauser'
|
|
23
|
+
end
|
|
24
|
+
end
|
|
@@ -6,4 +6,8 @@ class TwoCheckoutModuleTest < Test::Unit::TestCase
|
|
|
6
6
|
def test_notification_method
|
|
7
7
|
assert_instance_of TwoCheckout::Notification, TwoCheckout.notification('name=cody')
|
|
8
8
|
end
|
|
9
|
+
|
|
10
|
+
def test_return_method
|
|
11
|
+
assert_instance_of TwoCheckout::Return, TwoCheckout.return('name=cody')
|
|
12
|
+
end
|
|
9
13
|
end
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
require File.dirname(__FILE__) + '/../test_helper'
|
|
2
|
+
|
|
3
|
+
class SimpleGateway
|
|
4
|
+
include ActiveMerchant::PostsData
|
|
5
|
+
end
|
|
6
|
+
|
|
7
|
+
class MockResponse
|
|
8
|
+
def body
|
|
9
|
+
end
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
class PostsDataTests < Test::Unit::TestCase
|
|
13
|
+
URL = 'http://example.com'
|
|
14
|
+
|
|
15
|
+
def setup
|
|
16
|
+
@gateway = SimpleGateway.new
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
def teardown
|
|
20
|
+
SimpleGateway.retry_safe = false
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
def test_single_successful_post
|
|
24
|
+
Net::HTTP.any_instance.expects(:post).once.returns(MockResponse.new)
|
|
25
|
+
|
|
26
|
+
assert_nothing_raised do
|
|
27
|
+
@gateway.ssl_post(URL, '')
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
|
|
31
|
+
def test_multiple_successful_posts
|
|
32
|
+
responses = [ MockResponse.new, MockResponse.new ]
|
|
33
|
+
Net::HTTP.any_instance.expects(:post).times(2).returns(*responses)
|
|
34
|
+
|
|
35
|
+
assert_nothing_raised do
|
|
36
|
+
@gateway.ssl_post(URL, '')
|
|
37
|
+
@gateway.ssl_post(URL, '')
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
def test_unrecoverable_exception
|
|
42
|
+
Net::HTTP.any_instance.expects(:post).raises(EOFError)
|
|
43
|
+
|
|
44
|
+
assert_raises(ActiveMerchant::ConnectionError) do
|
|
45
|
+
@gateway.ssl_post(URL, '')
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
def test_failure_then_success_with_recoverable_exception
|
|
50
|
+
Net::HTTP.any_instance.expects(:post).times(2).raises(Errno::ECONNREFUSED).then.returns(MockResponse.new)
|
|
51
|
+
|
|
52
|
+
assert_nothing_raised do
|
|
53
|
+
@gateway.ssl_post(URL, '')
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
def test_failure_limit_reached
|
|
58
|
+
Net::HTTP.any_instance.expects(:post).times(ActiveMerchant::PostsData::MAX_RETRIES).raises(Errno::ECONNREFUSED)
|
|
59
|
+
|
|
60
|
+
assert_raises(ActiveMerchant::ConnectionError) do
|
|
61
|
+
@gateway.ssl_post(URL, '')
|
|
62
|
+
end
|
|
63
|
+
end
|
|
64
|
+
|
|
65
|
+
def test_failure_then_success_with_retry_safe_enabled
|
|
66
|
+
Net::HTTP.any_instance.expects(:post).times(2).raises(EOFError).then.returns(MockResponse.new)
|
|
67
|
+
|
|
68
|
+
@gateway.retry_safe = true
|
|
69
|
+
|
|
70
|
+
assert_nothing_raised do
|
|
71
|
+
@gateway.ssl_post(URL, '')
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
def test_mixture_of_failures_with_retry_safe_enabled
|
|
76
|
+
Net::HTTP.any_instance.expects(:post).times(3).raises(Errno::ECONNRESET).
|
|
77
|
+
raises(Errno::ECONNREFUSED).
|
|
78
|
+
raises(EOFError)
|
|
79
|
+
|
|
80
|
+
@gateway.retry_safe = true
|
|
81
|
+
|
|
82
|
+
assert_raises(ActiveMerchant::ConnectionError) do
|
|
83
|
+
@gateway.ssl_post(URL, '')
|
|
84
|
+
end
|
|
85
|
+
end
|
|
86
|
+
end
|
data/test/unit/response_test.rb
CHANGED
|
@@ -9,6 +9,20 @@ class ResponseTest < Test::Unit::TestCase
|
|
|
9
9
|
def test_get_params
|
|
10
10
|
response = Response.new(true, 'message', :param => 'value')
|
|
11
11
|
|
|
12
|
-
assert_equal ['param'], response.params.keys
|
|
12
|
+
assert_equal ['param'], response.params.keys
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def test_avs_result
|
|
16
|
+
response = Response.new(true, 'message', {}, :avs_result => { :code => 'A', :street_match => 'Y', :zip_match => 'N' })
|
|
17
|
+
avs_result = response.avs_result
|
|
18
|
+
assert_equal 'A', avs_result['code']
|
|
19
|
+
assert_equal AVSResult.messages['A'], avs_result['message']
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def test_cvv_result
|
|
23
|
+
response = Response.new(true, 'message', {}, :cvv_result => 'M')
|
|
24
|
+
cvv_result = response.cvv_result
|
|
25
|
+
assert_equal 'M', cvv_result['code']
|
|
26
|
+
assert_equal CVVResult.messages['M'], cvv_result['message']
|
|
13
27
|
end
|
|
14
28
|
end
|
|
@@ -3,11 +3,12 @@ require File.dirname(__FILE__) + '/../test_helper'
|
|
|
3
3
|
class Dood
|
|
4
4
|
include ActiveMerchant::Validateable
|
|
5
5
|
|
|
6
|
-
attr_accessor :name, :email
|
|
6
|
+
attr_accessor :name, :email, :country
|
|
7
7
|
|
|
8
8
|
def validate
|
|
9
9
|
errors.add "name", "cannot be empty" if name.blank?
|
|
10
10
|
errors.add "email", "cannot be empty" if email.blank?
|
|
11
|
+
errors.add_to_base "The country cannot be blank" if country.blank?
|
|
11
12
|
end
|
|
12
13
|
|
|
13
14
|
end
|
|
@@ -24,8 +25,8 @@ class ValidateableTest < Test::Unit::TestCase
|
|
|
24
25
|
assert ! @dood.errors.empty?
|
|
25
26
|
end
|
|
26
27
|
|
|
27
|
-
def
|
|
28
|
-
@dood = Dood.new(:name => "tobi", :email => "tobi@neech.de")
|
|
28
|
+
def test_assigns
|
|
29
|
+
@dood = Dood.new(:name => "tobi", :email => "tobi@neech.de", :country => 'DE')
|
|
29
30
|
|
|
30
31
|
assert_equal "tobi", @dood.name
|
|
31
32
|
assert_equal "tobi@neech.de", @dood.email
|
|
@@ -34,10 +35,13 @@ class ValidateableTest < Test::Unit::TestCase
|
|
|
34
35
|
|
|
35
36
|
def test_multiple_calls
|
|
36
37
|
@dood.name = "tobi"
|
|
37
|
-
assert
|
|
38
|
+
assert !@dood.valid?
|
|
39
|
+
|
|
38
40
|
@dood.email = "tobi@neech.de"
|
|
41
|
+
assert !@dood.valid?
|
|
42
|
+
|
|
43
|
+
@dood.country = 'DE'
|
|
39
44
|
assert @dood.valid?
|
|
40
|
-
|
|
41
45
|
end
|
|
42
46
|
|
|
43
47
|
def test_messages
|
|
@@ -50,7 +54,7 @@ class ValidateableTest < Test::Unit::TestCase
|
|
|
50
54
|
|
|
51
55
|
def test_full_messages
|
|
52
56
|
@dood.valid?
|
|
53
|
-
assert_equal ["Email cannot be empty", "Name cannot be empty"], @dood.errors.full_messages.sort
|
|
57
|
+
assert_equal ["Email cannot be empty", "Name cannot be empty", "The country cannot be blank"], @dood.errors.full_messages.sort
|
|
54
58
|
end
|
|
55
59
|
|
|
56
60
|
end
|
metadata
CHANGED
|
@@ -1,29 +1,12 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
|
-
rubygems_version: 0.9.4
|
|
3
|
-
specification_version: 1
|
|
4
2
|
name: activemerchant
|
|
5
3
|
version: !ruby/object:Gem::Version
|
|
6
|
-
version: 1.
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
- lib
|
|
11
|
-
email: tobi@leetsoft.com
|
|
12
|
-
homepage: http://activemerchant.org/
|
|
13
|
-
rubyforge_project:
|
|
14
|
-
description:
|
|
4
|
+
version: 1.3.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Tobias Luetke
|
|
15
8
|
autorequire: active_merchant
|
|
16
|
-
default_executable:
|
|
17
9
|
bindir: bin
|
|
18
|
-
has_rdoc: true
|
|
19
|
-
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
|
20
|
-
requirements:
|
|
21
|
-
- - ">"
|
|
22
|
-
- !ruby/object:Gem::Version
|
|
23
|
-
version: 0.0.0
|
|
24
|
-
version:
|
|
25
|
-
platform: ruby
|
|
26
|
-
signing_key:
|
|
27
10
|
cert_chain:
|
|
28
11
|
- |
|
|
29
12
|
-----BEGIN CERTIFICATE-----
|
|
@@ -47,27 +30,48 @@ cert_chain:
|
|
|
47
30
|
hPaSTyVU0yCSnw==
|
|
48
31
|
-----END CERTIFICATE-----
|
|
49
32
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
33
|
+
date: 2008-01-28 00:00:00 -05:00
|
|
34
|
+
default_executable:
|
|
35
|
+
dependencies:
|
|
36
|
+
- !ruby/object:Gem::Dependency
|
|
37
|
+
name: activesupport
|
|
38
|
+
version_requirement:
|
|
39
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
40
|
+
requirements:
|
|
41
|
+
- - ">="
|
|
42
|
+
- !ruby/object:Gem::Version
|
|
43
|
+
version: 1.4.1
|
|
44
|
+
version:
|
|
45
|
+
- !ruby/object:Gem::Dependency
|
|
46
|
+
name: builder
|
|
47
|
+
version_requirement:
|
|
48
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
49
|
+
requirements:
|
|
50
|
+
- - ">="
|
|
51
|
+
- !ruby/object:Gem::Version
|
|
52
|
+
version: 2.0.0
|
|
53
|
+
version:
|
|
54
|
+
description:
|
|
55
|
+
email: tobi@leetsoft.com
|
|
56
|
+
executables: []
|
|
57
|
+
|
|
58
|
+
extensions: []
|
|
59
|
+
|
|
60
|
+
extra_rdoc_files: []
|
|
61
|
+
|
|
53
62
|
files:
|
|
54
63
|
- lib/active_merchant
|
|
55
|
-
- lib/active_merchant.rb
|
|
56
|
-
- lib/certs
|
|
57
|
-
- lib/support
|
|
58
|
-
- lib/tasks
|
|
59
64
|
- lib/active_merchant/billing
|
|
60
|
-
- lib/active_merchant/
|
|
65
|
+
- lib/active_merchant/billing/avs_result.rb
|
|
61
66
|
- lib/active_merchant/billing/base.rb
|
|
67
|
+
- lib/active_merchant/billing/check.rb
|
|
62
68
|
- lib/active_merchant/billing/credit_card.rb
|
|
63
69
|
- lib/active_merchant/billing/credit_card_formatting.rb
|
|
64
70
|
- lib/active_merchant/billing/credit_card_methods.rb
|
|
71
|
+
- lib/active_merchant/billing/cvv_result.rb
|
|
72
|
+
- lib/active_merchant/billing/expiry_date.rb
|
|
65
73
|
- lib/active_merchant/billing/gateway.rb
|
|
66
74
|
- lib/active_merchant/billing/gateways
|
|
67
|
-
- lib/active_merchant/billing/gateways.rb
|
|
68
|
-
- lib/active_merchant/billing/integrations
|
|
69
|
-
- lib/active_merchant/billing/integrations.rb
|
|
70
|
-
- lib/active_merchant/billing/response.rb
|
|
71
75
|
- lib/active_merchant/billing/gateways/authorize_net.rb
|
|
72
76
|
- lib/active_merchant/billing/gateways/bogus.rb
|
|
73
77
|
- lib/active_merchant/billing/gateways/brain_tree.rb
|
|
@@ -80,14 +84,21 @@ files:
|
|
|
80
84
|
- lib/active_merchant/billing/gateways/linkpoint.rb
|
|
81
85
|
- lib/active_merchant/billing/gateways/moneris.rb
|
|
82
86
|
- lib/active_merchant/billing/gateways/net_registry.rb
|
|
87
|
+
- lib/active_merchant/billing/gateways/netbilling.rb
|
|
83
88
|
- lib/active_merchant/billing/gateways/pay_junction.rb
|
|
89
|
+
- lib/active_merchant/billing/gateways/pay_secure.rb
|
|
84
90
|
- lib/active_merchant/billing/gateways/payflow
|
|
91
|
+
- lib/active_merchant/billing/gateways/payflow/payflow_common_api.rb
|
|
92
|
+
- lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb
|
|
93
|
+
- lib/active_merchant/billing/gateways/payflow/payflow_response.rb
|
|
85
94
|
- lib/active_merchant/billing/gateways/payflow.rb
|
|
86
95
|
- lib/active_merchant/billing/gateways/payflow_express.rb
|
|
87
96
|
- lib/active_merchant/billing/gateways/payflow_express_uk.rb
|
|
88
97
|
- lib/active_merchant/billing/gateways/payflow_uk.rb
|
|
89
98
|
- lib/active_merchant/billing/gateways/payment_express.rb
|
|
90
99
|
- lib/active_merchant/billing/gateways/paypal
|
|
100
|
+
- lib/active_merchant/billing/gateways/paypal/paypal_common_api.rb
|
|
101
|
+
- lib/active_merchant/billing/gateways/paypal/paypal_express_response.rb
|
|
91
102
|
- lib/active_merchant/billing/gateways/paypal.rb
|
|
92
103
|
- lib/active_merchant/billing/gateways/paypal_express.rb
|
|
93
104
|
- lib/active_merchant/billing/gateways/plugnpay.rb
|
|
@@ -97,104 +108,128 @@ files:
|
|
|
97
108
|
- lib/active_merchant/billing/gateways/quickpay.rb
|
|
98
109
|
- lib/active_merchant/billing/gateways/realex.rb
|
|
99
110
|
- lib/active_merchant/billing/gateways/secure_pay.rb
|
|
111
|
+
- lib/active_merchant/billing/gateways/secure_pay_tech.rb
|
|
112
|
+
- lib/active_merchant/billing/gateways/skip_jack.rb
|
|
100
113
|
- lib/active_merchant/billing/gateways/trans_first.rb
|
|
101
114
|
- lib/active_merchant/billing/gateways/trust_commerce.rb
|
|
102
115
|
- lib/active_merchant/billing/gateways/usa_epay.rb
|
|
103
116
|
- lib/active_merchant/billing/gateways/verifi.rb
|
|
104
117
|
- lib/active_merchant/billing/gateways/viaklix.rb
|
|
105
|
-
- lib/active_merchant/billing/gateways
|
|
106
|
-
- lib/active_merchant/billing/
|
|
107
|
-
- lib/active_merchant/billing/gateways/payflow/payflow_response.rb
|
|
108
|
-
- lib/active_merchant/billing/gateways/paypal/api_cert_chain.crt
|
|
109
|
-
- lib/active_merchant/billing/gateways/paypal/paypal_common_api.rb
|
|
110
|
-
- lib/active_merchant/billing/gateways/paypal/paypal_express_response.rb
|
|
118
|
+
- lib/active_merchant/billing/gateways.rb
|
|
119
|
+
- lib/active_merchant/billing/integrations
|
|
111
120
|
- lib/active_merchant/billing/integrations/action_view_helper.rb
|
|
112
121
|
- lib/active_merchant/billing/integrations/bogus
|
|
122
|
+
- lib/active_merchant/billing/integrations/bogus/helper.rb
|
|
123
|
+
- lib/active_merchant/billing/integrations/bogus/notification.rb
|
|
124
|
+
- lib/active_merchant/billing/integrations/bogus/return.rb
|
|
113
125
|
- lib/active_merchant/billing/integrations/bogus.rb
|
|
114
126
|
- lib/active_merchant/billing/integrations/chronopay
|
|
127
|
+
- lib/active_merchant/billing/integrations/chronopay/helper.rb
|
|
128
|
+
- lib/active_merchant/billing/integrations/chronopay/notification.rb
|
|
129
|
+
- lib/active_merchant/billing/integrations/chronopay/return.rb
|
|
115
130
|
- lib/active_merchant/billing/integrations/chronopay.rb
|
|
116
131
|
- lib/active_merchant/billing/integrations/gestpay
|
|
132
|
+
- lib/active_merchant/billing/integrations/gestpay/common.rb
|
|
133
|
+
- lib/active_merchant/billing/integrations/gestpay/helper.rb
|
|
134
|
+
- lib/active_merchant/billing/integrations/gestpay/notification.rb
|
|
135
|
+
- lib/active_merchant/billing/integrations/gestpay/return.rb
|
|
117
136
|
- lib/active_merchant/billing/integrations/gestpay.rb
|
|
118
137
|
- lib/active_merchant/billing/integrations/helper.rb
|
|
138
|
+
- lib/active_merchant/billing/integrations/hi_trust
|
|
139
|
+
- lib/active_merchant/billing/integrations/hi_trust/helper.rb
|
|
140
|
+
- lib/active_merchant/billing/integrations/hi_trust/notification.rb
|
|
141
|
+
- lib/active_merchant/billing/integrations/hi_trust/return.rb
|
|
142
|
+
- lib/active_merchant/billing/integrations/hi_trust.rb
|
|
119
143
|
- lib/active_merchant/billing/integrations/nochex
|
|
144
|
+
- lib/active_merchant/billing/integrations/nochex/helper.rb
|
|
145
|
+
- lib/active_merchant/billing/integrations/nochex/notification.rb
|
|
146
|
+
- lib/active_merchant/billing/integrations/nochex/return.rb
|
|
120
147
|
- lib/active_merchant/billing/integrations/nochex.rb
|
|
121
148
|
- lib/active_merchant/billing/integrations/notification.rb
|
|
122
149
|
- lib/active_merchant/billing/integrations/paypal
|
|
123
|
-
- lib/active_merchant/billing/integrations/paypal.rb
|
|
124
|
-
- lib/active_merchant/billing/integrations/two_checkout
|
|
125
|
-
- lib/active_merchant/billing/integrations/two_checkout.rb
|
|
126
|
-
- lib/active_merchant/billing/integrations/bogus/helper.rb
|
|
127
|
-
- lib/active_merchant/billing/integrations/bogus/notification.rb
|
|
128
|
-
- lib/active_merchant/billing/integrations/chronopay/helper.rb
|
|
129
|
-
- lib/active_merchant/billing/integrations/chronopay/notification.rb
|
|
130
|
-
- lib/active_merchant/billing/integrations/gestpay/common.rb
|
|
131
|
-
- lib/active_merchant/billing/integrations/gestpay/helper.rb
|
|
132
|
-
- lib/active_merchant/billing/integrations/gestpay/notification.rb
|
|
133
|
-
- lib/active_merchant/billing/integrations/nochex/helper.rb
|
|
134
|
-
- lib/active_merchant/billing/integrations/nochex/notification.rb
|
|
135
150
|
- lib/active_merchant/billing/integrations/paypal/helper.rb
|
|
136
151
|
- lib/active_merchant/billing/integrations/paypal/notification.rb
|
|
152
|
+
- lib/active_merchant/billing/integrations/paypal/return.rb
|
|
153
|
+
- lib/active_merchant/billing/integrations/paypal.rb
|
|
154
|
+
- lib/active_merchant/billing/integrations/return.rb
|
|
155
|
+
- lib/active_merchant/billing/integrations/two_checkout
|
|
137
156
|
- lib/active_merchant/billing/integrations/two_checkout/helper.rb
|
|
138
157
|
- lib/active_merchant/billing/integrations/two_checkout/notification.rb
|
|
158
|
+
- lib/active_merchant/billing/integrations/two_checkout/return.rb
|
|
159
|
+
- lib/active_merchant/billing/integrations/two_checkout.rb
|
|
160
|
+
- lib/active_merchant/billing/integrations.rb
|
|
161
|
+
- lib/active_merchant/billing/response.rb
|
|
162
|
+
- lib/active_merchant/lib
|
|
139
163
|
- lib/active_merchant/lib/country.rb
|
|
140
164
|
- lib/active_merchant/lib/error.rb
|
|
141
165
|
- lib/active_merchant/lib/post_data.rb
|
|
142
166
|
- lib/active_merchant/lib/posts_data.rb
|
|
143
167
|
- lib/active_merchant/lib/requires_parameters.rb
|
|
168
|
+
- lib/active_merchant/lib/utils.rb
|
|
144
169
|
- lib/active_merchant/lib/validateable.rb
|
|
170
|
+
- lib/active_merchant.rb
|
|
171
|
+
- lib/certs
|
|
145
172
|
- lib/certs/cacert.pem
|
|
173
|
+
- lib/support
|
|
146
174
|
- lib/support/gateway_support.rb
|
|
175
|
+
- lib/tasks
|
|
147
176
|
- lib/tasks/cia.rb
|
|
148
177
|
- test/extra
|
|
178
|
+
- test/extra/binding_of_caller.rb
|
|
179
|
+
- test/extra/breakpoint.rb
|
|
149
180
|
- test/fixtures.yml
|
|
150
|
-
- test/
|
|
181
|
+
- test/remote
|
|
182
|
+
- test/remote/gateways
|
|
183
|
+
- test/remote/gateways/remote_authorize_net_test.rb
|
|
184
|
+
- test/remote/gateways/remote_brain_tree_test.rb
|
|
185
|
+
- test/remote/gateways/remote_card_stream_test.rb
|
|
186
|
+
- test/remote/gateways/remote_cyber_source_test.rb
|
|
187
|
+
- test/remote/gateways/remote_data_cash_test.rb
|
|
188
|
+
- test/remote/gateways/remote_efsnet_test.rb
|
|
189
|
+
- test/remote/gateways/remote_eway_test.rb
|
|
190
|
+
- test/remote/gateways/remote_exact_test.rb
|
|
191
|
+
- test/remote/gateways/remote_linkpoint_test.rb
|
|
192
|
+
- test/remote/gateways/remote_moneris_test.rb
|
|
193
|
+
- test/remote/gateways/remote_net_registry_test.rb
|
|
194
|
+
- test/remote/gateways/remote_netbilling_test.rb
|
|
195
|
+
- test/remote/gateways/remote_pay_junction_test.rb
|
|
196
|
+
- test/remote/gateways/remote_pay_secure_test.rb
|
|
197
|
+
- test/remote/gateways/remote_payflow_express_test.rb
|
|
198
|
+
- test/remote/gateways/remote_payflow_test.rb
|
|
199
|
+
- test/remote/gateways/remote_payflow_uk_test.rb
|
|
200
|
+
- test/remote/gateways/remote_payment_express_test.rb
|
|
201
|
+
- test/remote/gateways/remote_paypal_express_test.rb
|
|
202
|
+
- test/remote/gateways/remote_paypal_test.rb
|
|
203
|
+
- test/remote/gateways/remote_plugnpay_test.rb
|
|
204
|
+
- test/remote/gateways/remote_protx_test.rb
|
|
205
|
+
- test/remote/gateways/remote_psigate_test.rb
|
|
206
|
+
- test/remote/gateways/remote_psl_card_test.rb
|
|
207
|
+
- test/remote/gateways/remote_quickpay_test.rb
|
|
208
|
+
- test/remote/gateways/remote_realex_test.rb
|
|
209
|
+
- test/remote/gateways/remote_secure_pay_tech_test.rb
|
|
210
|
+
- test/remote/gateways/remote_secure_pay_test.rb
|
|
211
|
+
- test/remote/gateways/remote_skipjack_test.rb
|
|
212
|
+
- test/remote/gateways/remote_trans_first_test.rb
|
|
213
|
+
- test/remote/gateways/remote_trust_commerce_test.rb
|
|
214
|
+
- test/remote/gateways/remote_usa_epay_test.rb
|
|
215
|
+
- test/remote/gateways/remote_verifi_test.rb
|
|
216
|
+
- test/remote/gateways/remote_viaklix_test.rb
|
|
217
|
+
- test/remote/integrations
|
|
218
|
+
- test/remote/integrations/remote_gestpay_integration_test.rb
|
|
219
|
+
- test/remote/integrations/remote_paypal_integration_test.rb
|
|
151
220
|
- test/test_helper.rb
|
|
152
221
|
- test/unit
|
|
153
|
-
- test/
|
|
154
|
-
- test/extra/breakpoint.rb
|
|
155
|
-
- test/remote_tests/remote_authorize_net_test.rb
|
|
156
|
-
- test/remote_tests/remote_brain_tree_test.rb
|
|
157
|
-
- test/remote_tests/remote_card_stream_test.rb
|
|
158
|
-
- test/remote_tests/remote_cyber_source_test.rb
|
|
159
|
-
- test/remote_tests/remote_data_cash_test.rb
|
|
160
|
-
- test/remote_tests/remote_efsnet_test.rb
|
|
161
|
-
- test/remote_tests/remote_eway_test.rb
|
|
162
|
-
- test/remote_tests/remote_exact_test.rb
|
|
163
|
-
- test/remote_tests/remote_gestpay_integration_test.rb
|
|
164
|
-
- test/remote_tests/remote_linkpoint_test.rb
|
|
165
|
-
- test/remote_tests/remote_moneris_test.rb
|
|
166
|
-
- test/remote_tests/remote_net_registry_test.rb
|
|
167
|
-
- test/remote_tests/remote_pay_junction_test.rb
|
|
168
|
-
- test/remote_tests/remote_payflow_express_test.rb
|
|
169
|
-
- test/remote_tests/remote_payflow_test.rb
|
|
170
|
-
- test/remote_tests/remote_payflow_uk_test.rb
|
|
171
|
-
- test/remote_tests/remote_payment_express_test.rb
|
|
172
|
-
- test/remote_tests/remote_paypal_express_test.rb
|
|
173
|
-
- test/remote_tests/remote_paypal_integration_test.rb
|
|
174
|
-
- test/remote_tests/remote_paypal_test.rb
|
|
175
|
-
- test/remote_tests/remote_plugnpay_test.rb
|
|
176
|
-
- test/remote_tests/remote_protx_test.rb
|
|
177
|
-
- test/remote_tests/remote_psigate_test.rb
|
|
178
|
-
- test/remote_tests/remote_psl_card_test.rb
|
|
179
|
-
- test/remote_tests/remote_quickpay_test.rb
|
|
180
|
-
- test/remote_tests/remote_realex_test.rb
|
|
181
|
-
- test/remote_tests/remote_secure_pay_test.rb
|
|
182
|
-
- test/remote_tests/remote_trans_first_test.rb
|
|
183
|
-
- test/remote_tests/remote_trust_commerce_test.rb
|
|
184
|
-
- test/remote_tests/remote_usa_epay_test.rb
|
|
185
|
-
- test/remote_tests/remote_verifi_test.rb
|
|
186
|
-
- test/remote_tests/remote_viaklix_test.rb
|
|
222
|
+
- test/unit/avs_result_test.rb
|
|
187
223
|
- test/unit/base_test.rb
|
|
224
|
+
- test/unit/check_test.rb
|
|
188
225
|
- test/unit/country_code_test.rb
|
|
189
226
|
- test/unit/country_test.rb
|
|
190
227
|
- test/unit/credit_card_formatting_test.rb
|
|
191
228
|
- test/unit/credit_card_methods_test.rb
|
|
192
229
|
- test/unit/credit_card_test.rb
|
|
230
|
+
- test/unit/cvv_result_test.rb
|
|
231
|
+
- test/unit/expiry_date_test.rb
|
|
193
232
|
- test/unit/gateways
|
|
194
|
-
- test/unit/integrations
|
|
195
|
-
- test/unit/post_data_test.rb
|
|
196
|
-
- test/unit/response_test.rb
|
|
197
|
-
- test/unit/validateable_test.rb
|
|
198
233
|
- test/unit/gateways/authorize_net_test.rb
|
|
199
234
|
- test/unit/gateways/bogus_test.rb
|
|
200
235
|
- test/unit/gateways/brain_tree_test.rb
|
|
@@ -208,7 +243,9 @@ files:
|
|
|
208
243
|
- test/unit/gateways/linkpoint_test.rb
|
|
209
244
|
- test/unit/gateways/moneris_test.rb
|
|
210
245
|
- test/unit/gateways/net_registry_test.rb
|
|
246
|
+
- test/unit/gateways/netbilling_test.rb
|
|
211
247
|
- test/unit/gateways/pay_junction_test.rb
|
|
248
|
+
- test/unit/gateways/pay_secure_test.rb
|
|
212
249
|
- test/unit/gateways/payflow_express_test.rb
|
|
213
250
|
- test/unit/gateways/payflow_express_uk_test.rb
|
|
214
251
|
- test/unit/gateways/payflow_test.rb
|
|
@@ -222,93 +259,94 @@ files:
|
|
|
222
259
|
- test/unit/gateways/psl_card_test.rb
|
|
223
260
|
- test/unit/gateways/quickpay_test.rb
|
|
224
261
|
- test/unit/gateways/realex_test.rb
|
|
262
|
+
- test/unit/gateways/secure_pay_tech_test.rb
|
|
225
263
|
- test/unit/gateways/secure_pay_test.rb
|
|
264
|
+
- test/unit/gateways/skip_jack_test.rb
|
|
226
265
|
- test/unit/gateways/trans_first_test.rb
|
|
227
266
|
- test/unit/gateways/trust_commerce_test.rb
|
|
228
267
|
- test/unit/gateways/usa_epay_test.rb
|
|
229
268
|
- test/unit/gateways/verifi_test.rb
|
|
230
269
|
- test/unit/gateways/viaklix_test.rb
|
|
270
|
+
- test/unit/generators
|
|
271
|
+
- test/unit/generators/test_gateway_generator.rb
|
|
272
|
+
- test/unit/generators/test_generator_helper.rb
|
|
273
|
+
- test/unit/generators/test_integration_generator.rb
|
|
274
|
+
- test/unit/integrations
|
|
231
275
|
- test/unit/integrations/action_view_helper_test.rb
|
|
232
276
|
- test/unit/integrations/bogus_module_test.rb
|
|
233
277
|
- test/unit/integrations/chronopay_module_test.rb
|
|
234
278
|
- test/unit/integrations/gestpay_module_test.rb
|
|
235
279
|
- test/unit/integrations/helpers
|
|
236
|
-
- test/unit/integrations/nochex_module_test.rb
|
|
237
|
-
- test/unit/integrations/notifications
|
|
238
|
-
- test/unit/integrations/paypal_module_test.rb
|
|
239
|
-
- test/unit/integrations/two_checkout_module_test.rb
|
|
240
280
|
- test/unit/integrations/helpers/bogus_helper_test.rb
|
|
241
281
|
- test/unit/integrations/helpers/chronopay_helper_test.rb
|
|
242
282
|
- test/unit/integrations/helpers/gestpay_helper_test.rb
|
|
283
|
+
- test/unit/integrations/helpers/hi_trust_helper_test.rb
|
|
243
284
|
- test/unit/integrations/helpers/nochex_helper_test.rb
|
|
244
285
|
- test/unit/integrations/helpers/paypal_helper_test.rb
|
|
245
286
|
- test/unit/integrations/helpers/two_checkout_helper_test.rb
|
|
287
|
+
- test/unit/integrations/hi_trust_module_test.rb
|
|
288
|
+
- test/unit/integrations/nochex_module_test.rb
|
|
289
|
+
- test/unit/integrations/notifications
|
|
246
290
|
- test/unit/integrations/notifications/chronopay_notification_test.rb
|
|
247
291
|
- test/unit/integrations/notifications/gestpay_notification_test.rb
|
|
292
|
+
- test/unit/integrations/notifications/hi_trust_notification_test.rb
|
|
248
293
|
- test/unit/integrations/notifications/nochex_notification_test.rb
|
|
249
294
|
- test/unit/integrations/notifications/notification_test.rb
|
|
250
295
|
- test/unit/integrations/notifications/paypal_notification_test.rb
|
|
251
296
|
- test/unit/integrations/notifications/two_checkout_notification_test.rb
|
|
297
|
+
- test/unit/integrations/paypal_module_test.rb
|
|
298
|
+
- test/unit/integrations/returns
|
|
299
|
+
- test/unit/integrations/returns/chronopay_return_test.rb
|
|
300
|
+
- test/unit/integrations/returns/gestpay_return_test.rb
|
|
301
|
+
- test/unit/integrations/returns/hi_trust_return_test.rb
|
|
302
|
+
- test/unit/integrations/returns/nochex_return_test.rb
|
|
303
|
+
- test/unit/integrations/returns/paypal_return_test.rb
|
|
304
|
+
- test/unit/integrations/returns/return_test.rb
|
|
305
|
+
- test/unit/integrations/returns/two_checkout_return_test.rb
|
|
306
|
+
- test/unit/integrations/two_checkout_module_test.rb
|
|
307
|
+
- test/unit/post_data_test.rb
|
|
308
|
+
- test/unit/posts_data_test.rb
|
|
309
|
+
- test/unit/response_test.rb
|
|
310
|
+
- test/unit/utils_test.rb
|
|
311
|
+
- test/unit/validateable_test.rb
|
|
312
|
+
- script/destroy
|
|
252
313
|
- script/generate
|
|
253
|
-
- script/generator
|
|
254
|
-
- script/generator/base.rb
|
|
255
|
-
- script/generator/generator.rb
|
|
256
|
-
- script/generator/generators
|
|
257
|
-
- script/generator/manifest.rb
|
|
258
|
-
- script/generator/generators/gateway
|
|
259
|
-
- script/generator/generators/integration
|
|
260
|
-
- script/generator/generators/gateway/gateway_generator.rb
|
|
261
|
-
- script/generator/generators/gateway/templates
|
|
262
|
-
- script/generator/generators/gateway/templates/gateway.rb
|
|
263
|
-
- script/generator/generators/gateway/templates/gateway_test.rb
|
|
264
|
-
- script/generator/generators/gateway/templates/remote_gateway_test.rb
|
|
265
|
-
- script/generator/generators/integration/integration_generator.rb
|
|
266
|
-
- script/generator/generators/integration/templates
|
|
267
|
-
- script/generator/generators/integration/templates/helper.rb
|
|
268
|
-
- script/generator/generators/integration/templates/helper_test.rb
|
|
269
|
-
- script/generator/generators/integration/templates/integration.rb
|
|
270
|
-
- script/generator/generators/integration/templates/module_test.rb
|
|
271
|
-
- script/generator/generators/integration/templates/notification.rb
|
|
272
|
-
- script/generator/generators/integration/templates/notification_test.rb
|
|
273
314
|
- CHANGELOG
|
|
274
315
|
- CONTRIBUTERS
|
|
275
316
|
- gem-public_cert.pem
|
|
317
|
+
- generators
|
|
276
318
|
- init.rb
|
|
277
319
|
- lib
|
|
278
320
|
- MIT-LICENSE
|
|
279
|
-
- pkg
|
|
280
321
|
- Rakefile
|
|
281
322
|
- README
|
|
282
323
|
- script
|
|
283
324
|
- test
|
|
284
|
-
|
|
285
|
-
|
|
325
|
+
has_rdoc: true
|
|
326
|
+
homepage: http://activemerchant.org/
|
|
327
|
+
post_install_message:
|
|
286
328
|
rdoc_options: []
|
|
287
329
|
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
330
|
+
require_paths:
|
|
331
|
+
- lib
|
|
332
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
333
|
+
requirements:
|
|
334
|
+
- - ">="
|
|
335
|
+
- !ruby/object:Gem::Version
|
|
336
|
+
version: "0"
|
|
337
|
+
version:
|
|
338
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
339
|
+
requirements:
|
|
340
|
+
- - ">="
|
|
341
|
+
- !ruby/object:Gem::Version
|
|
342
|
+
version: "0"
|
|
343
|
+
version:
|
|
294
344
|
requirements: []
|
|
295
345
|
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
- !ruby/object:Gem::Version
|
|
304
|
-
version: 1.4.1
|
|
305
|
-
version:
|
|
306
|
-
- !ruby/object:Gem::Dependency
|
|
307
|
-
name: builder
|
|
308
|
-
version_requirement:
|
|
309
|
-
version_requirements: !ruby/object:Gem::Version::Requirement
|
|
310
|
-
requirements:
|
|
311
|
-
- - ">="
|
|
312
|
-
- !ruby/object:Gem::Version
|
|
313
|
-
version: 2.0.0
|
|
314
|
-
version:
|
|
346
|
+
rubyforge_project:
|
|
347
|
+
rubygems_version: 1.0.1
|
|
348
|
+
signing_key:
|
|
349
|
+
specification_version: 2
|
|
350
|
+
summary: Framework and tools for dealing with credit card transactions.
|
|
351
|
+
test_files: []
|
|
352
|
+
|