Skip to content

Commit 4738dc2

Browse files
authored
MAGE-1078: separate classes to prevent phpcs to report an error (#1637)
1 parent ec4c5d9 commit 4738dc2

File tree

2 files changed

+14
-10
lines changed

2 files changed

+14
-10
lines changed

Test/Unit/ConfigHelperTest.php

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
namespace Algolia\AlgoliaSearch\Test\Unit;
44

5-
use Algolia\AlgoliaSearch\Helper\ConfigHelper;
65
use Magento\Cookie\Helper\Cookie as CookieHelper;
76
use Magento\Customer\Api\GroupExcludedWebsiteRepositoryInterface;
87
use Magento\Customer\Model\ResourceModel\Group\Collection as GroupCollection;
@@ -18,15 +17,6 @@
1817
use Magento\Store\Model\StoreManagerInterface;
1918
use PHPUnit\Framework\TestCase;
2019

21-
class ConfigHelperTestable extends ConfigHelper
22-
{
23-
/** expose protected methods for unit testing */
24-
public function serialize(array $value): string
25-
{
26-
return parent::serialize($value);
27-
}
28-
}
29-
3020
class ConfigHelperTest extends TestCase
3121
{
3222
protected ConfigHelperTestable $configHelper;

Test/Unit/ConfigHelperTestable.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
namespace Algolia\AlgoliaSearch\Test\Unit;
4+
5+
use Algolia\AlgoliaSearch\Helper\ConfigHelper;
6+
7+
class ConfigHelperTestable extends ConfigHelper
8+
{
9+
/** expose protected methods for unit testing */
10+
public function serialize(array $value): string
11+
{
12+
return parent::serialize($value);
13+
}
14+
}

0 commit comments

Comments
 (0)