ConfigTimerTest   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 2
dl 0
loc 25
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A testFactory() 0 13 1
1
<?php
2
/*
3
 * This file is part of the php-utilities package.
4
 *
5
 * (c) Marc Aschmann <[email protected]>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
namespace Asm\Tests\Config;
11
12
use Asm\Config\Config;
13
use Asm\Test\BaseConfigTest;
14
15
/**
16
 * Class ConfigTimerTest
17
 *
18
 * @package Asm\Tests\Config
19
 * @author Marc Aschmann <[email protected]>
20
 */
21
class ConfigTimerTest extends BaseConfigTest
22
{
23
    /**
24
     * @covers \Asm\Config\ConfigTimer::setConfig
25
     * @covers \Asm\Config\ConfigTimer::handleTimers
26
     * @covers \Asm\Config\ConfigTimer::handleHolidays
27
     * @covers \Asm\Config\ConfigTimer::handleGeneralHolidays
28
     * @covers \Asm\Test\BaseConfigTest::getTimerYaml
29
     * @return ConfigTimer $config
30
     * @throws \ErrorException
31
     */
32
    public function testFactory()
33
    {
34
        $config = Config::factory(
35
            [
36
                'file' => $this->getTimerYaml(),
37
            ],
38
            'ConfigTimer'
39
        );
40
41
        $this->assertInstanceOf('Asm\Config\ConfigTimer', $config);
42
43
        return $config;
44
    }
45
}
46