Completed
Push — master ( 7ca809...e10277 )
by GBProd
02:21
created

testBuildAddCompilerPass()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 12
Code Lines 8

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 12
rs 9.4285
cc 1
eloc 8
nc 1
nop 0
1
<?php
2
3
namespace Tests\GBProd\DoctrineSpecificationBundle;
4
5
use GBProd\DoctrineSpecificationBundle\DoctrineSpecificationBundle;
6
use Symfony\Component\DependencyInjection\ContainerBuilder;
7
use GBProd\DoctrineSpecificationBundle\DependencyInjection\Compiler\ExpressionBuilderPass;
8
9
/**
10
 * Tests for Bundle
11
 * 
12
 * @author gbprod <[email protected]>
13
 */
14
class DoctrineSpecificationBundleTest extends \PHPUnit_Framework_TestCase
15
{
16
    public function testConstruct()
17
    {
18
        new DoctrineSpecificationBundle();
19
    }
20
    
21
    public function testBuildAddCompilerPass()
22
    {
23
        $container = $this->getMock(ContainerBuilder::class);
24
        $container
25
            ->expects($this->once())
26
            ->method('addCompilerPass')
27
            ->with($this->isInstanceOf(ExpressionBuilderPass::class))
28
        ;
29
        
30
        $bundle = new DoctrineSpecificationBundle();
31
        $bundle->build($container);
32
    }
33
}
34