Guzzle6Test   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 3
dl 0
loc 17
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A testHasGuzzle6Client() 0 10 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace MovingImage\Bundle\VMProApiBundle\Tests\DependencyInjection\VMProApiExtensionTest;
6
7
use MovingImage\Bundle\VMProApiBundle\DependencyInjection\VMProApiExtension;
8
use MovingImage\Bundle\VMProApiBundle\Tests\DependencyInjection\AbstractTestCase;
9
use MovingImage\Client\VMPro\ApiClient\Guzzle6ApiClient;
10
use Symfony\Component\DependencyInjection\ContainerBuilder;
11
12
class Guzzle6Test extends AbstractTestCase
13
{
14
    /**
15
     * Assert whether when Guzzle ^6.0 is installed, the right instance
16
     * of the API client is placed in the dependency injection container.
17
     */
18
    public function testHasGuzzle6Client(): void
19
    {
20
        $container = new ContainerBuilder();
21
        $loader = new VMProApiExtension();
22
        $config = $this->getFullConfig();
23
24
        $loader->load($config, $container);
25
26
        $this->assertInstanceOf(Guzzle6ApiClient::class, $container->get('vmpro_api.client'));
27
    }
28
}
29