Completed
Pull Request — master (#15)
by Wachter
06:21
created

TaskHandlerFactoryTest   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 4

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A setUp() 0 7 1
A testRun() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of php-task library.
5
 *
6
 * (c) php-task
7
 *
8
 * This source file is subject to the MIT license that is bundled
9
 * with this source code in the file LICENSE.
10
 */
11
12
namespace Functional;
13
14
use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
15
use Task\TaskBundle\Handler\TaskHandlerFactory;
16
17
class TaskHandlerFactoryTest extends KernelTestCase
18
{
19
    /**
20
     * @var TaskHandlerFactory
21
     */
22
    private $taskHandlerFactory;
23
24
    protected function setUp()
25
    {
26
        parent::setUp();
27
28
        $this->bootKernel();
29
        $this->taskHandlerFactory = self::$kernel->getContainer()->get('task.handler.factory');
30
    }
31
32
    public function testRun()
33
    {
34
        $this->assertInstanceOf(\TestHandler::class, $this->taskHandlerFactory->create(\TestHandler::class));
35
    }
36
}
37