Test Setup Failed
Push — master ( 7450ca...e4bb3e )
by Gabriel
05:50 queued 15s
created

AbstractRouteTraitTest::testSetParams()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 9

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 0
dl 0
loc 9
rs 9.9666
c 0
b 0
f 0
1
<?php
2
3
namespace Nip\Router\Tests\Legacy\Route;
4
5
use Nip\Router\Route\Route;
6
use Nip\Router\Tests\AbstractTest;
7
8
/**
9
 * Class AbstractRouteTraitTest
10
 * @package Nip\Router\Tests\Legacy\Route
11
 */
12
class AbstractRouteTraitTest extends AbstractTest
13
{
14
    public function testSetParams()
15
    {
16
        $route = new Route();
17
        self::assertSame([], $route->getDefaults());
18
19
        $params = ['test' => 9];
20
        $route->setParams($params);
0 ignored issues
show
Deprecated Code introduced by
The method Nip\Router\Legacy\Route\...RouteTrait::setParams() has been deprecated with message: Use setDefaults

This method has been deprecated. The supplier of the class has supplied an explanatory message.

The explanatory message should give you some clue as to whether and when the method will be removed from the class and what other method or class to use instead.

Loading history...
21
        self::assertSame($params, $route->getDefaults());
22
    }
23
}
24