Fix phpunit

This commit is contained in:
Emili Castells Guasch 2023-07-11 14:20:11 +02:00
parent ab1880f0da
commit f1eda7d3e3

View file

@ -25,6 +25,7 @@ use WooCommerce\PayPalCommerce\Vaulting\PaymentTokenRepository;
use WooCommerce\PayPalCommerce\WcGateway\Gateway\PayPalGateway;
use WooCommerce\PayPalCommerce\WcGateway\Processor\AuthorizedPaymentsProcessor;
use WooCommerce\PayPalCommerce\WcGateway\Settings\Settings;
use function Brain\Monkey\Functions\when;
class RenewalHandlerTest extends TestCase
{
@ -154,6 +155,8 @@ class RenewalHandlerTest extends TestCase
->with([$purchaseUnit], 'no_shipping', $payer, $token)
->andReturn($order);
when('wcs_get_subscriptions_for_order')->justReturn(array());
$wcOrder->shouldReceive('update_status');
$wcOrder->shouldReceive('save');