Authorize.net Support Added to magium/magento
Authorize.net payment method support has been added to magium/magento. Now you can have your tests switch to use the Authorize.net payment method in checkout. Note, it does not, yet, support automated configuration. You’ll need to do that ahead of time.
SNIPPET!!
<?php
// add declarations
class AuthorizeNetPaymentTest extends AbstractMagentoTestCase
{
public function testAuthorizeNet()
{
$this->commandOpen($this->getTheme()->getBaseUrl());
$this->getAction(AddItemToCart::ACTION)->addSimpleProductToCartFromCategoryPage();
$this->setPaymentMethod('AuthorizeNet');
$this->getPaymentInformation()->setCreditCardNumber('4007000000027');
$this->getAction(GuestCheckout::ACTION)->execute();
}
}
But it gets even better! You can have a new payment information class automatically configure the test case to run using the Authorize.net-provided defaults
<?php
// add declarations
class AuthorizeNetPaymentTest extends AbstractMagentoTestCase
{
public function testConfigureAuthorizeNet()
{
$this->commandOpen($this->getTheme()->getBaseUrl());
$this->getAction(AddItemToCart::ACTION)->addSimpleProductToCartFromCategoryPage();
$payment = $this->getAction(AuthorizeNet::ACTION);
$payment->configureTest($this);
$payment->setUseMastercard();
$this->getAction(CustomerCheckout::ACTION)->execute();
}
}