Completed
Push — master ( c92b89...bb4046 )
by Razon
10:10 queued 08:29
created

ComposerHelper   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 3
dl 0
loc 11
rs 10
c 1
b 0
f 0
ccs 3
cts 3
cp 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A getVendorPath() 0 4 1
1
<?php
2
namespace RazonYang\MediaWiki\ZhConverter;
3
4
use Composer\Autoload\ClassLoader;
5
6
class ComposerHelper
7
{
8
    /**
9
     * Gets composer vendor path.
10
     *
11
     * @return string
12
     */
13 1
    public static function getVendorPath()
14
    {
15 1
        $reflection = new \ReflectionClass(ClassLoader::class);
16 1
        return dirname(dirname($reflection->getFileName()));
17
    }
18
}
19