GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( f00db0...375331 )
by Benjamin
03:40
created

RouterTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A testMatcherIsCalled() 0 23 1
1
<?php
2
3
namespace Tests\Lib\Routing;
4
5
use Lib\Http\Request;
6
use Lib\Routing\RouteLoader;
7
use Lib\Routing\Router;
8
use Lib\Routing\UrlMatcher;
9
use PHPUnit\Framework\TestCase;
10
use PHPUnit\Framework\MockObject\MockObject;
11
12
class RouterTest extends TestCase
13
{
14
    public function testMatcherIsCalled()
15
    {
16
        /* @var UrlMatcher&MockObject */
17
        $matcher = $this
18
            ->getMockBuilder(UrlMatcher::class)
19
            ->disableOriginalConstructor()
20
            ->disableOriginalClone()
21
            ->disallowMockingUnknownTypes()
22
            ->setMethods(['match'])
23
            ->getMock();
24
        /* @var RouteLoader&MockObject */
25
        $loader = $this
26
            ->getMockBuilder(RouteLoader::class)
27
            ->disableOriginalConstructor()
28
            ->disableOriginalClone()
29
            ->disallowMockingUnknownTypes()
30
            ->getMock();
31
32
        $router = new Router($loader, $matcher);
33
34
        $matcher->expects($this->once())->method('match');
35
36
        $router->route(new Request());
37
    }
38
}
39