Business-OnlinePayment-InternetSecure
view release on metacpan - search on metacpan
view release on metacpan or search on metacpan
my $txn = new Business::OnlinePayment 'InternetSecure', merchant_id => '0000';
foreach (TRANSACTIONS) {
$txn->test_transaction(delete $_->{_test});
$txn->content(%$_);
my $data = do {
# Work around bug #17687
local $/ = '';
scalar <DATA>;
};
is_deeply(
xml_in($txn->to_xml),
xml_in($data)
);
}
t/30parse.t view on Meta::CPAN
use Test::More tests => 1 + scalar(RESULTS) * (1 + 1 + scalar(FIELDS));
BEGIN { use_ok('Business::OnlinePayment') };
my $txn = new Business::OnlinePayment 'InternetSecure', merchant_id => '0000';
$/ = '';
foreach my $results (RESULTS) {
my $xml = <DATA>;
$txn->parse_response($xml);
is($txn->server_response, $xml, 'server_response');
if ($results->{is_success}) {
ok($txn->is_success, 'expecting success');
} else {
ok(!$txn->is_success, 'expecting failure');
view all matches for this distributionview release on metacpan - search on metacpan
( run in 1.968 second using v1.00-cache-2.02-grep-82fe00e-cpan-d29e8ade9f55 )