Code Duplication    Length = 18-18 lines in 2 locations

Test/Unit/Helper/ConfigTest.php 1 location

@@ 54-71 (lines=18) @@
51
     */
52
    private $scopeConfig;
53
54
    protected function setUp()
55
    {
56
        $this->objectManager = new ObjectManager($this);
57
58
        $this->scopeConfig = $this->getMockBuilder(ScopeConfigInterface::class)->disableOriginalConstructor()->getMock();
59
        $context = $this->objectManager->getObject(Context::class, ['scopeConfig' => $this->scopeConfig]);
60
61
        $store = $this->getMockBuilder(StoreInterface::class)->disableOriginalConstructor()->getMock();
62
        $store->method('getCode')->willReturn(null);
63
64
        $storeManager = $this->getMockBuilder(StoreManagerInterface::class)->disableOriginalConstructor()->getMock();
65
        $storeManager->method('getStore')->willReturn($store);
66
67
        $this->config = $this->objectManager->getObject(Config::class, [
68
            'context' => $context,
69
            'storeManager' => $storeManager
70
        ]);
71
    }
72
73
    public function testGetConfigParamEmpty()
74
    {

Test/Unit/Helper/PaymentTest.php 1 location

@@ 55-72 (lines=18) @@
52
     */
53
    private $scopeConfig;
54
55
    protected function setUp()
56
    {
57
        $this->objectManager = new ObjectManager($this);
58
59
        $this->scopeConfig = $this->getMockBuilder(ScopeConfigInterface::class)->disableOriginalConstructor()->getMock();
60
        $context = $this->objectManager->getObject(Context::class, ['scopeConfig' => $this->scopeConfig]);
61
62
        $store = $this->getMockBuilder(StoreInterface::class)->disableOriginalConstructor()->getMock();
63
        $store->method('getCode')->willReturn(null);
64
65
        $storeManager = $this->getMockBuilder(StoreManagerInterface::class)->disableOriginalConstructor()->getMock();
66
        $storeManager->method('getStore')->willReturn($store);
67
68
        $this->payment = $this->objectManager->getObject(Payment::class, [
69
            'context' => $context,
70
            'storeManager' => $storeManager
71
        ]);
72
    }
73
74
    public function testGetAvailablePaymentTypes()
75
    {