HasTypeTraitTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 5
dl 0
loc 12
rs 10
c 1
b 0
f 1
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A testGetTypeFromName() 0 4 1
A testGetTypeLiteralForSimpleRoute() 0 4 1
1
<?php
2
3
namespace Nip\Router\Tests\Route\Traits;
4
5
use Nip\Router\Route\Route;
6
use Nip\Router\Tests\AbstractTest;
7
use Nip\Router\Tests\Fixtures\Application\Library\Router\Route\StandardRoute;
8
9
/**
10
 * Class HasTypeTraitTest
11
 * @package Nip\Router\Tests\Route\Traits
12
 */
13
class HasTypeTraitTest extends AbstractTest
14
{
15
    public static function testGetTypeLiteralForSimpleRoute()
16
    {
17
        $route = new Route();
18
        static::assertSame('literal', $route->getType());
19
    }
20
21
    public static function testGetTypeFromName()
22
    {
23
        $route = new StandardRoute();
24
        static::assertSame('standard', $route->getType());
25
    }
26
}
27