GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 39-39 lines in 2 locations

lib/Magento/Actions/Checkout/PaymentMethods/CashOnDelivery.php 1 location

@@ 8-46 (lines=39) @@
5
use Magium\Magento\AbstractMagentoTestCase;
6
use Magium\WebDriver\WebDriver;
7
8
class CashOnDelivery implements PaymentMethodInterface
9
{
10
11
    const ACTION = 'Checkout\PaymentMethods\CashOnDelivery';
12
13
    protected $webDriver;
14
    protected $testCase;
15
16
    public function __construct(
17
        WebDriver                   $webDriver,
18
        AbstractMagentoTestCase     $testCase
19
    ) {
20
        $this->webDriver    = $webDriver;
21
        $this->testCase     = $testCase;
22
    }
23
24
    public function getId()
25
    {
26
        return 'p_method_cashondelivery';
27
    }
28
29
    /**
30
     * Fills in the payment form, selecting it, if necessary
31
     *
32
     * @param $requirePayment
33
     */
34
35
    public function pay($requirePayment)
36
    {
37
        if ($requirePayment) {
38
            $this->testCase->assertElementExists($this->getId());
39
        }
40
41
        if ($this->webDriver->elementDisplayed($this->getId())) {
42
            $element = $this->webDriver->byId($this->getId());
43
            $this->webDriver->getMouse()->click($element->getCoordinates());
44
        }
45
    }
46
}

lib/Magento/Actions/Checkout/PaymentMethods/CheckMoneyOrder.php 1 location

@@ 8-46 (lines=39) @@
5
use Magium\Magento\AbstractMagentoTestCase;
6
use Magium\WebDriver\WebDriver;
7
8
class CheckMoneyOrder implements PaymentMethodInterface
9
{
10
11
    const ACTION = 'Checkout\PaymentMethods\CheckMoneyOrder';
12
13
    protected $webDriver;
14
    protected $testCase;
15
16
    public function __construct(
17
        WebDriver                   $webDriver,
18
        AbstractMagentoTestCase     $testCase
19
    ) {
20
        $this->webDriver    = $webDriver;
21
        $this->testCase     = $testCase;
22
    }
23
24
    public function getId()
25
    {
26
        return 'p_method_checkmo';
27
    }
28
29
    /**
30
     * Fills in the payment form, selecting it, if necessary
31
     *
32
     * @param $requirePayment
33
     */
34
35
    public function pay($requirePayment)
36
    {
37
        if ($requirePayment) {
38
            $this->testCase->assertElementExists($this->getId());
39
        }
40
41
        if ($this->webDriver->elementDisplayed($this->getId())) {
42
            $element = $this->webDriver->byId($this->getId());
43
            $this->webDriver->getMouse()->click($element->getCoordinates());
44
        }
45
    }
46
}
47