Skip to content

Commit

Permalink
remove comments, redundant code and add namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
RokPopov committed Jan 18, 2024
1 parent b880b7c commit 78d3e45
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
12 changes: 9 additions & 3 deletions Test/Unit/Gateway/Http/Client/TransactionPaymentTest.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
<?php
/**
*
* Adyen Payment module (https://www.adyen.com/)
*
* Copyright (c) 2024 Adyen N.V. (https://www.adyen.com/)
* See LICENSE.txt for license details.
*
* Author: Adyen <magento@adyen.com>
*/

namespace Adyen\Payment\Test\Unit\Gateway\Http\Client;

Expand Down Expand Up @@ -33,7 +42,6 @@ protected function setUp(): void
$objectManager = new ObjectManager($this);

$this->adyenHelperMock = $this->createMock(Data::class);
$this->paymentResponseFactoryMock = $this->createGeneratedMock(PaymentResponseFactory::class, ['create']);
$this->paymentResponseResourceModelMock = $this->createMock(PaymentResponseResourceModel::class);
$this->idempotencyHelperMock = $this->createMock(Idempotency::class);
$this->orderApiHelperMock = $this->createMock(OrdersApi::class);
Expand All @@ -44,8 +52,6 @@ protected function setUp(): void
$paymentResponseMock->method('setResponse')->willReturn($paymentResponseInterfaceMock);
$paymentResponseMock->method('setResultCode')->willReturn($paymentResponseInterfaceMock);
$paymentResponseMock->method('setMerchantReference')->willReturn($paymentResponseInterfaceMock);

// Configure PaymentResponseFactory mock to return the PaymentResponse mock
$this->paymentResponseFactoryMock = $this->createGeneratedMock(PaymentResponseFactory::class, ['create']);
$this->paymentResponseFactoryMock->method('create')->willReturn($paymentResponseMock);

Expand Down
5 changes: 2 additions & 3 deletions Test/Unit/Helper/PaymentDetailsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
*
* Adyen Payment module (https://www.adyen.com/)
*
* Copyright (c) 2023 Adyen N.V. (https://www.adyen.com/)
* Copyright (c) 2024 Adyen N.V. (https://www.adyen.com/)
* See LICENSE.txt for license details.
*
* Author: Adyen <magento@adyen.com>
*/
namespace Adyen\Payment\Test\Unit\Helper;

use Adyen\Payment\Helper\PaymentsDetails;
use Adyen\Payment\Test\Unit\AbstractAdyenTestCase;
Expand All @@ -17,9 +18,7 @@
use Adyen\Payment\Logger\AdyenLogger;
use Adyen\Payment\Helper\PaymentResponseHandler;
use Adyen\Payment\Helper\Idempotency;
use Adyen\AdyenException;
use Magento\Checkout\Model\Session;
use Magento\Framework\Exception\ValidatorException;
use Adyen\Service\Checkout;
use Adyen\Client;

Expand Down

0 comments on commit 78d3e45

Please sign in to comment.