Merge pull request #1506 from woocommerce/PCP-1169-order-does-not-contain-intent

Order does not contain intent error (1169)
This commit is contained in:
Emili Castells 2023-08-30 10:52:35 +02:00 committed by GitHub
commit b6642d185c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 37 additions and 19 deletions

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
{
@ -157,6 +158,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');