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 = 51-51 lines in 3 locations

src/MageTest/PhpSpec/MagentoExtension/Locator/Magento/BlockResource.php 1 location

@@ 34-84 (lines=51) @@
31
 *
32
 * @author     MageTest team (https://github.com/MageTest/MageSpec/contributors)
33
 */
34
class BlockResource implements ResourceInterface
35
{
36
    private $parts;
37
    private $locator;
38
39
    public function __construct(array $parts, BlockLocator $locator)
40
    {
41
        $this->parts   = $parts;
42
        $this->locator = $locator;
43
    }
44
45
    public function getName()
46
    {
47
        return implode('_', $this->parts);
48
    }
49
50
    public function getSpecName()
51
    {
52
        return $this->getName() . 'Spec';
53
    }
54
55
    public function getSrcFilename()
56
    {
57
        return $this->locator->getFullSrcPath() . implode(DIRECTORY_SEPARATOR, $this->parts) . '.php';
58
    }
59
60
    public function getSrcNamespace()
61
    {
62
        return '';
63
    }
64
65
    public function getSrcClassname()
66
    {
67
        return implode('_', $this->parts);
68
    }
69
70
    public function getSpecFilename()
71
    {
72
        return $this->locator->getFullSpecPath() . implode(DIRECTORY_SEPARATOR, $this->parts) . 'Spec.php';
73
    }
74
75
    public function getSpecNamespace()
76
    {
77
        return rtrim($this->locator->getSpecNamespace(), '/\\');
78
    }
79
80
    public function getSpecClassname()
81
    {
82
        return $this->locator->getSpecNamespace() . implode('_', $this->parts).'Spec';
83
    }
84
}

src/MageTest/PhpSpec/MagentoExtension/Locator/Magento/HelperResource.php 1 location

@@ 34-84 (lines=51) @@
31
 *
32
 * @author     MageTest team (https://github.com/MageTest/MageSpec/contributors)
33
 */
34
class HelperResource implements ResourceInterface
35
{
36
    private $parts;
37
    private $locator;
38
39
    public function __construct(array $parts, HelperLocator $locator)
40
    {
41
        $this->parts   = $parts;
42
        $this->locator = $locator;
43
    }
44
45
    public function getName()
46
    {
47
        return implode('_', $this->parts);
48
    }
49
50
    public function getSpecName()
51
    {
52
        return $this->getName() . 'Spec';
53
    }
54
55
    public function getSrcFilename()
56
    {
57
        return $this->locator->getFullSrcPath() . implode(DIRECTORY_SEPARATOR, $this->parts) . '.php';
58
    }
59
60
    public function getSrcNamespace()
61
    {
62
        return '';
63
    }
64
65
    public function getSrcClassname()
66
    {
67
        return implode('_', $this->parts);
68
    }
69
70
    public function getSpecFilename()
71
    {
72
        return $this->locator->getFullSpecPath() . implode(DIRECTORY_SEPARATOR, $this->parts) . 'Spec.php';
73
    }
74
75
    public function getSpecNamespace()
76
    {
77
        return rtrim($this->locator->getSpecNamespace(), '/\\');
78
    }
79
80
    public function getSpecClassname()
81
    {
82
        return $this->locator->getSpecNamespace() . implode('_', $this->parts).'Spec';
83
    }
84
}

src/MageTest/PhpSpec/MagentoExtension/Locator/Magento/ModelResource.php 1 location

@@ 34-84 (lines=51) @@
31
 *
32
 * @author     MageTest team (https://github.com/MageTest/MageSpec/contributors)
33
 */
34
class ModelResource implements ResourceInterface
35
{
36
    private $parts;
37
    private $locator;
38
39
    public function __construct(array $parts, ModelLocator $locator)
40
    {
41
        $this->parts   = $parts;
42
        $this->locator = $locator;
43
    }
44
45
    public function getName()
46
    {
47
        return implode('_', $this->parts);
48
    }
49
50
    public function getSpecName()
51
    {
52
        return $this->getName() . 'Spec';
53
    }
54
55
    public function getSrcFilename()
56
    {
57
        return $this->locator->getFullSrcPath() . implode(DIRECTORY_SEPARATOR, $this->parts) . '.php';
58
    }
59
60
    public function getSrcNamespace()
61
    {
62
        return '';
63
    }
64
65
    public function getSrcClassname()
66
    {
67
        return implode('_', $this->parts);
68
    }
69
70
    public function getSpecFilename()
71
    {
72
        return $this->locator->getFullSpecPath() . implode(DIRECTORY_SEPARATOR, $this->parts) . 'Spec.php';
73
    }
74
75
    public function getSpecNamespace()
76
    {
77
        return rtrim($this->locator->getSpecNamespace(), '/\\');
78
    }
79
80
    public function getSpecClassname()
81
    {
82
        return $this->locator->getSpecNamespace() . implode('_', $this->parts).'Spec';
83
    }
84
}