From e9a8450242559f58aa2535a489d7a7acc85790e2 Mon Sep 17 00:00:00 2001 From: ivan Date: Wed, 16 Mar 2005 10:37:56 +0000 Subject: initial import --- t/bad_card.t | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 t/bad_card.t (limited to 't/bad_card.t') diff --git a/t/bad_card.t b/t/bad_card.t new file mode 100644 index 0000000..afd324b --- /dev/null +++ b/t/bad_card.t @@ -0,0 +1,35 @@ +BEGIN {$| = 1; print "1..1\n"; } + +eval "use Net::SSLeay;"; +if ( $@ ) { + print "ok 1 # Skipped: Net::SSLeay is not installed\n"; exit; +} + +use Business::OnlinePayment; + +my $tx = new Business::OnlinePayment("eSelectPlus"); + +#$Business::OnlinePayment::HTTPS::DEBUG = 1; +#$Business::OnlinePayment::HTTPS::DEBUG = 1; +#$Business::OnlinePayment::eSelectPlus::DEBUG = 1; +#$Business::OnlinePayment::eSelectPlus::DEBUG = 1; + +$tx->content( + type => 'VISA', + login => 'store1', + password => 'yesguy', + action => 'Normal Authorization', + amount => '32.32', + card_number => '4242424242424242', + expiration => '08/06', +); +$tx->test_transaction(1); # test, dont really charge +$tx->submit(); + +if($tx->is_success()) { + print "not ok 1\n"; +} else { + #warn $tx->server_response."\n"; + #warn $tx->error_message. "\n"; + print "ok 1\n"; +} -- cgit v1.2.1