Sha256: e664558e40f6c5cc094fef16ac04503d7a836e319a46c33e4437d21fe740dd07
Contents?: true
Size: 710 Bytes
Versions: 2
Compression:
Stored size: 710 Bytes
Contents
require 'test_helper' class HiTrustReturnTest < Test::Unit::TestCase include AbtainBilling::Billing::Integrations def test_successful_return r = HiTrust::Return.new('order_id=&mscssid=&retcode=00&ordernumber=1138742&type=Auth') assert r.success? assert_equal HiTrust::Return::SUCCESS, r.params['retcode'] assert_equal HiTrust::Return::CODES[HiTrust::Return::SUCCESS], r.message end def test_failed_return r = HiTrust::Return.new('retcode=-100') assert_false r.success? assert_equal HiTrust::Return::CODES['-100'], r.message end def test_unknown_return r = HiTrust::Return.new('retcode=unknown') assert_false r.success? assert_nil r.message end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
abtain_billing-1.03 | test/unit/integrations/returns/hi_trust_return_test.rb |
abtain_billing-1.02 | test/unit/integrations/returns/hi_trust_return_test.rb |