ConfigurationTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 4

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
c 1
b 0
f 0
lcom 1
cbo 4
dl 0
loc 27
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A setUp() 0 4 1
A testGetConfigTreeBuilder() 0 8 1
1
<?php
2
3
/*
4
 * This file is part of the Kickbox Bundle.
5
 *
6
 * (c) Abdoul Ndiaye <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Andi\KickBoxBundle\Tests\DependencyInjection;
13
14
use Andi\KickBoxBundle\DependencyInjection\Configuration;
15
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
16
17
class ConfigurationTest extends \PHPUnit_Framework_TestCase
18
{
19
    /**
20
     * @var Configuration
21
     */
22
    protected $configuration;
23
24
    /**
25
     * {@inheritdoc}
26
     */
27
    protected function setUp()
28
    {
29
        $this->configuration = new Configuration();
30
    }
31
32
    /**
33
     * Get ConfigTreeBuilder test
34
     */
35
    public function testGetConfigTreeBuilder()
36
    {
37
        $treeBuilder = $this->configuration->getConfigTreeBuilder();
38
        $this->assertInstanceOf(TreeBuilder::class, $treeBuilder);
39
40
        $tree = $treeBuilder->buildTree();
41
        $this->assertTrue($tree->getName() === 'andi_kick_box');
42
    }
43
}
44