NAME

Business::OnlinePayment::Mock - Business::OnlinePayment::Mock - A backend for mocking fake results for test cards

VERSION

version 0.001

SYNOPSIS

DESCRIPTION

METHODS

set_default_mock

Sets the default mock for the Business::OnlinePayment object

$mock->set_default_mock({
  error_message => 'Declined',
  is_success    => 0,
  error_code    => 100,
  order_number  => 1,
});

set_mock_response

Sets the mock response the Business::OnlinePayment object

$mock->set_mock_response({
  error_message => 'Approved',
  is_success    => 1,
  error_code    => 0,
  order_number  => 1,
});

test_transaction

Get/set the server used for processing transactions. Because we are mocked, this method effectively does nothing. Default: Live

#Live
$self->test_transaction(0);

#Certification
$self->test_transaction(1);

submit

Submit the content to the mocked API

$self->content(action => 'Credit' ...)

$self->submit;

NAME

Business::OnlinePayment::Mock - A backend for mocking fake results in the Business::OnlinePayment environment

AUTHOR

Jason Terry <oaxlin@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2018 by Jason Terry.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.