diff options
Diffstat (limited to 't2')
-rw-r--r-- | t2/bad_auth.t | 4 | ||||
-rw-r--r-- | t2/credit_card.t | 4 | ||||
-rw-r--r-- | t2/echeck.t | 41 |
3 files changed, 45 insertions, 4 deletions
diff --git a/t2/bad_auth.t b/t2/bad_auth.t index 2374eaf..689b0cc 100644 --- a/t2/bad_auth.t +++ b/t2/bad_auth.t @@ -3,7 +3,7 @@ BEGIN { $| = 1; print "1..1\n"; } use Business::OnlinePayment; my $tx = new Business::OnlinePayment("LinkPoint", - 'storename' => '1909100155', + 'storename' => '1909922411', 'keyfile' => './test.pem', ); @@ -21,7 +21,7 @@ $tx->content( country => 'US', email => 'ivan-linkpoint@420.am', card_number => '4007000000027', - expiration => '12/2005', + expiration => '12/2008', result => 'DECLINE', ); diff --git a/t2/credit_card.t b/t2/credit_card.t index b70e9c0..0748c6a 100644 --- a/t2/credit_card.t +++ b/t2/credit_card.t @@ -3,7 +3,7 @@ BEGIN { $| = 1; print "1..1\n"; } use Business::OnlinePayment; my $tx = new Business::OnlinePayment("LinkPoint", - 'storename' => '1909100155', + 'storename' => '1909922411', 'keyfile' => './test.pem', ); @@ -21,7 +21,7 @@ $tx->content( country => 'US', email => 'ivan-linkpoint@420.am', card_number => '4007000000027', - expiration => '12/2005', + expiration => '12/2008', ); $tx->test_transaction(1); diff --git a/t2/echeck.t b/t2/echeck.t new file mode 100644 index 0000000..b21d5d4 --- /dev/null +++ b/t2/echeck.t @@ -0,0 +1,41 @@ +BEGIN { $| = 1; print "1..1\n"; } + +use Business::OnlinePayment; + +my $tx = new Business::OnlinePayment("LinkPoint", + 'storename' => '1909922411', + 'keyfile' => './test.pem', +); + +$tx->content( + type => 'CHECK', + action => 'Normal Authorization', + description => 'Business::OnlinePayment::LinkPoint visa test', + amount => '0.01', + first_name => 'Tofu', + last_name => 'Beast', + address => '123 Anystreet', + city => 'Anywhere', + state => 'UT', + zip => '84058', + country => 'US', + email => 'ivan-linkpoint@420.am', + card_number => '4007000000027', + expiration => '12/2008', + bankstate => 'UT', +); + +$tx->test_transaction(1); + +$tx->submit(); + +if($tx->is_success()) { + print "ok 1\n"; + $auth = $tx->authorization; + warn "********* $auth ***********\n"; +} else { + print "not ok 1\n"; + warn '***** '. $tx->error_message. " *****\n"; + exit; +} + |