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.

RouterTest::testMatcherIsCalled()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 23
Code Lines 16

Duplication

Lines 0
Ratio 0 %

Importance

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