woocommerce-paypal-payments/tests/integration/PHPUnit/TestCase.php
2025-03-12 18:14:01 +01:00

31 lines
622 B
PHP

<?php
declare(strict_types=1);
namespace WooCommerce\PayPalCommerce\Tests\Integration;
use WooCommerce\PayPalCommerce\PPCP;
use WooCommerce\PayPalCommerce\Vendor\Psr\Container\ContainerInterface;
use WC_Cart;
use WC_Customer;
use WC_Session;
class TestCase extends \PHPUnit\Framework\TestCase
{
protected $container;
protected function getContainer(): ContainerInterface {
return PPCP::container();
}
protected function cart(): WC_Cart {
return WC()->cart;
}
protected function customer(): WC_Customer {
return WC()->customer;
}
protected function session(): WC_Session {
return WC()->session;
}
}