Completed
Pull Request — master (#47)
by David
01:40
created

EmptyContainerTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 8
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 5
dl 0
loc 8
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A testContainer() 0 6 1
1
<?php
2
3
namespace TheCodingMachine\GraphQL\Controllers\Containers;
4
5
use PHPUnit\Framework\TestCase;
6
use Psr\Container\NotFoundExceptionInterface;
7
8
class EmptyContainerTest extends TestCase
9
{
10
    public function testContainer()
11
    {
12
        $container = new EmptyContainer();
13
        $this->assertFalse($container->has('foo'));
14
        $this->expectException(NotFoundExceptionInterface::class);
15
        $container->get('foo');
16
    }
17
}
18