Test Failed
Pull Request — master (#102)
by Rustam
02:27
created

ProxyServiceProvider   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getDefinitions() 0 5 1
A getExtensions() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Yiisoft\Yii\Debug;
6
7
use Psr\Container\ContainerInterface;
8
use Yiisoft\Di\Contracts\ServiceProviderInterface;
9
use Yiisoft\Yii\Debug\Proxy\ContainerInterfaceProxy;
10
use Yiisoft\Yii\Debug\Proxy\ContainerProxyConfig;
11
12
final class ProxyServiceProvider implements ServiceProviderInterface
13
{
14
    /**
15
     * @psalm-suppress InaccessibleMethod
16
     */
17
    public function getDefinitions(): array
18 1
    {
19
        return [
20 1
            ContainerInterface::class => static function (ContainerInterface $container) {
21 1
                return new ContainerInterfaceProxy($container, $container->get(ContainerProxyConfig::class));
22 1
            },
23 1
        ];
24 1
    }
25
26 1
    public function getExtensions(): array
27
    {
28
        return [];
29
    }
30
}
31