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.
Passed
Push — develop ( d433ef...8d7806 )
by Baptiste
02:53
created

CpuTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 13
c 1
b 0
f 1
dl 0
loc 18
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A testInterface() 0 16 1
1
<?php
2
declare(strict_types = 1);
3
4
namespace Tests\Innmind\Server\Status\Server;
5
6
use Innmind\Server\Status\Server\{
7
    Cpu,
8
    Cpu\Percentage,
9
    Cpu\Cores,
10
};
11
use PHPUnit\Framework\TestCase;
12
13
class CpuTest extends TestCase
14
{
15
    public function testInterface()
16
    {
17
        $cpu = new Cpu(
18
            $user = new Percentage(31),
19
            $system = new Percentage(33),
20
            $idle = new Percentage(36),
21
            $cores = new Cores(4)
22
        );
23
24
        $this->assertSame($user, $cpu->user());
25
        $this->assertSame($system, $cpu->system());
26
        $this->assertSame($idle, $cpu->idle());
27
        $this->assertSame($cores, $cpu->cores());
28
        $this->assertSame(
29
            'CPU usage: 31% user, 33% sys, 36% idle',
30
            $cpu->toString(),
31
        );
32
    }
33
}
34