Passed
Push — trunk ( 49986f...44ff76 )
by Christian
22:08 queued 08:23
created

RefundTestPaymentHandler::refund()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 2
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php declare(strict_types=1);
2
3
namespace Shopware\Core\Test\Integration\PaymentHandler;
4
5
use Shopware\Core\Checkout\Order\Aggregate\OrderTransactionCaptureRefund\OrderTransactionCaptureRefundStateHandler;
6
use Shopware\Core\Checkout\Payment\Cart\PaymentHandler\RefundPaymentHandlerInterface;
7
use Shopware\Core\Framework\Context;
8
use Shopware\Core\Framework\Log\Package;
9
10
/**
11
 * @internal
12
 */
13
#[Package('checkout')]
14
class RefundTestPaymentHandler implements RefundPaymentHandlerInterface
15
{
16
    public function __construct(private readonly OrderTransactionCaptureRefundStateHandler $stateHandler)
17
    {
18
    }
19
20
    public function refund(string $refundId, Context $context): void
21
    {
22
        $this->stateHandler->complete($refundId, $context);
23
    }
24
}
25