untested update for linkpoint 2.6 changes, ick
[Business-OnlinePayment-LinkPoint.git] / t2 / bad_auth.t
1 BEGIN { $| = 1; print "1..1\n"; }
2
3 use Business::OnlinePayment;
4
5 my $tx = new Business::OnlinePayment("LinkPoint",
6   'storename' => '1909100155',
7   'keyfile'   => './test.pem',
8 );
9
10 $tx->content(
11     type           => 'VISA',
12     action         => 'Normal Authorization',
13     description    => 'Business::OnlinePayment::LinkPoint visa test',
14     amount         => '0.01',
15     first_name     => 'Tofu',
16     last_name      => 'Beast',
17     address        => '123 Anystreet',
18     city           => 'Anywhere',
19     state          => 'UT',
20     zip            => '84058',
21     country        => 'US',
22     email          => 'ivan-linkpoint@420.am',
23     card_number    => '4007000000027',
24     expiration     => '12/2005',
25     result         => 'DECLINE',
26 );
27
28 $tx->test_transaction(1);
29
30 $tx->submit();
31
32 if($tx->is_success()) {
33     print "not ok 1\n";
34     $auth = $tx->authorization;
35     warn "********* $auth ***********\n";
36 } else {
37     print "ok 1\n";
38     warn '***** '. $tx->error_message. " *****\n";
39     exit;
40 }
41