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.

ContextTest   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 12
c 0
b 0
f 0
dl 0
loc 19
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A testContext() 0 17 1
1
<?php
2
/* (c) Anton Medvedev <[email protected]>
3
 *
4
 * For the full copyright and license information, please view the LICENSE
5
 * file that was distributed with this source code.
6
 */
7
8
namespace Deployer\Task;
9
10
use Deployer\Configuration;
11
use Deployer\Host\Host;
12
use PHPUnit\Framework\TestCase;
13
use Symfony\Component\Console\Input\InputInterface;
14
use Symfony\Component\Console\Output\OutputInterface;
15
16
class ContextTest extends TestCase
17
{
18
    public function testContext()
19
    {
20
        $host = $this->getMockBuilder(Host::class)->disableOriginalConstructor()->getMock();
21
        $host
22
            ->expects($this->once())
23
            ->method('config')
24
            ->willReturn($this->createMock(Configuration::class));
25
26
        $context = new Context($host);
27
28
        $this->assertInstanceOf(Host::class, $context->getHost());
29
        $this->assertInstanceOf(Configuration::class, $context->getConfig());
30
31
        Context::push($context);
32
33
        $this->assertEquals($context, Context::get());
34
        $this->assertEquals($context, Context::pop());
35
    }
36
}
37