diff --git a/tests/unit/test-class-wc-payment-gateway-wcpay-payment-types.php b/tests/unit/test-class-wc-payment-gateway-wcpay-payment-types.php index 8caaadb9ea4..c4ae5f729ee 100644 --- a/tests/unit/test-class-wc-payment-gateway-wcpay-payment-types.php +++ b/tests/unit/test-class-wc-payment-gateway-wcpay-payment-types.php @@ -9,6 +9,7 @@ use WCPay\Core\Server\Request\Create_And_Confirm_Intention; use WCPay\Constants\Payment_Method; use WCPay\Duplicate_Payment_Prevention_Service; +use WCPay\Duplicates_Detection_Service; use WCPay\Session_Rate_Limiter; use WCPay\Fraud_Prevention\Fraud_Prevention_Service; use WCPay\Payment_Methods\CC_Payment_Method; @@ -153,6 +154,7 @@ public function set_up() { $mock_dpps, $this->createMock( WC_Payments_Localization_Service::class ), $this->createMock( WC_Payments_Fraud_Service::class ), + $this->createMock( Duplicates_Detection_Service::class ), ] ) ->setMethods( diff --git a/tests/unit/test-class-wc-payment-gateway-wcpay-process-payment.php b/tests/unit/test-class-wc-payment-gateway-wcpay-process-payment.php index 79f6cd75d9b..3962272376d 100644 --- a/tests/unit/test-class-wc-payment-gateway-wcpay-process-payment.php +++ b/tests/unit/test-class-wc-payment-gateway-wcpay-process-payment.php @@ -15,6 +15,7 @@ use WCPay\Exceptions\Connection_Exception; use WCPay\Session_Rate_Limiter; use WCPay\Constants\Payment_Method; +use WCPay\Duplicates_Detection_Service; use WCPay\Payment_Methods\CC_Payment_Method; // Need to use WC_Mock_Data_Store. @@ -167,6 +168,7 @@ public function set_up() { $this->mock_dpps, $this->createMock( WC_Payments_Localization_Service::class ), $this->createMock( WC_Payments_Fraud_Service::class ), + $this->createMock( Duplicates_Detection_Service::class ), ] ) ->setMethods( diff --git a/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-payment-method-order-note.php b/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-payment-method-order-note.php index 9715d61a193..fd4352ac0b2 100644 --- a/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-payment-method-order-note.php +++ b/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-payment-method-order-note.php @@ -6,6 +6,7 @@ */ use WCPay\Duplicate_Payment_Prevention_Service; +use WCPay\Duplicates_Detection_Service; use WCPay\Payment_Methods\CC_Payment_Method; use WCPay\Session_Rate_Limiter; @@ -139,7 +140,8 @@ public function set_up() { $this->mock_order_service, $mock_dpps, $this->createMock( WC_Payments_Localization_Service::class ), - $this->createMock( WC_Payments_Fraud_Service::class ) + $this->createMock( WC_Payments_Fraud_Service::class ), + $this->createMock( Duplicates_Detection_Service::class ), ); $this->wcpay_gateway->init_hooks(); diff --git a/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-process-payment.php b/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-process-payment.php index 434bbd971fd..622e7cbe1d9 100644 --- a/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-process-payment.php +++ b/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions-process-payment.php @@ -10,6 +10,7 @@ use WCPay\Constants\Order_Status; use WCPay\Constants\Intent_Status; use WCPay\Duplicate_Payment_Prevention_Service; +use WCPay\Duplicates_Detection_Service; use WCPay\Payment_Methods\CC_Payment_Method; use WCPay\Session_Rate_Limiter; @@ -160,6 +161,7 @@ public function set_up() { $mock_dpps, $this->createMock( WC_Payments_Localization_Service::class ), $this->createMock( WC_Payments_Fraud_Service::class ), + $this->createMock( Duplicates_Detection_Service::class ), ] ) ->setMethods( diff --git a/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions.php b/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions.php index a5b33c1581c..4e50568e8b6 100644 --- a/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions.php +++ b/tests/unit/test-class-wc-payment-gateway-wcpay-subscriptions.php @@ -8,6 +8,7 @@ use PHPUnit\Framework\MockObject\MockObject; use WCPay\Core\Server\Request\Create_And_Confirm_Intention; use WCPay\Duplicate_Payment_Prevention_Service; +use WCPay\Duplicates_Detection_Service; use WCPay\Exceptions\API_Exception; use WCPay\Internal\Service\Level3Service; use WCPay\Internal\Service\OrderService; @@ -156,7 +157,8 @@ public function set_up() { $this->order_service, $this->mock_dpps, $this->mock_localization_service, - $this->mock_fraud_service + $this->mock_fraud_service, + $this->createMock( Duplicates_Detection_Service::class ), ); $this->wcpay_gateway->init_hooks(); WC_Payments::set_gateway( $this->wcpay_gateway );