mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-08-31 06:52:50 +08:00
Add refunds support for bancontact gateway and fix tests
This commit is contained in:
parent
fee2b0ff0f
commit
3dc3026c29
5 changed files with 84 additions and 44 deletions
|
@ -11,7 +11,11 @@ class OrdersTest extends TestCase
|
|||
$host = 'https://api-m.sandbox.paypal.com';
|
||||
$container = $this->getContainer();
|
||||
|
||||
$orders = new Orders($host, $container->get('api.bearer'));
|
||||
$orders = new Orders(
|
||||
$host,
|
||||
$container->get('api.bearer'),
|
||||
$container->get( 'woocommerce.logger.woocommerce' )
|
||||
);
|
||||
|
||||
$requestBody = [
|
||||
"intent" => "CAPTURE",
|
||||
|
@ -38,11 +42,7 @@ class OrdersTest extends TestCase
|
|||
]
|
||||
];
|
||||
|
||||
$headers = array(
|
||||
'PayPal-Request-Id' => uniqid( 'ppcp-', true ),
|
||||
);
|
||||
|
||||
$result = $orders->create($requestBody, $headers);
|
||||
$result = $orders->create($requestBody);
|
||||
|
||||
$this->assertEquals(200, $result['response']['code']);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue