Completed
Push — standalone ( d5557b...6e54cd )
by Philip
02:01
created

MinimalEnvironmentTest::getBundleClasses()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 6
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 3
nc 1
nop 0
1
<?php
2
3
namespace Dontdrinkandroot\RestBundle\Tests\Functional;
4
5
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
6
use Symfony\Component\HttpFoundation\Request;
7
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
8
9
class MinimalEnvironmentTest extends FunctionalTestCase
10
{
11
    protected $environment = 'minimal';
12
13
    public function testList()
14
    {
15
        $client = $this->makeClient();
16
17
        $client->request(
18
            Request::METHOD_GET,
19
            '/rest/minimalentities',
20
            [],
21
            [],
22
            []
23
        );
24
        $content = $this->assertJsonResponse($client->getResponse());
25
        $this->assertCount(0, $content);
26
    }
27
28
    public function testBla()
29
    {
30
        $client = $this->makeClient();
31
32
        $this->expectException(NotFoundHttpException::class);
33
34
        $client->request(
35
            Request::METHOD_GET,
36
            '/rest/test',
37
            [],
38
            [],
39
            []
40
        );
41
    }
42
43
    /**
44
     * {@inheritdoc}
45
     */
46
    protected function getFixtureClasses()
47
    {
48
        return [];
49
    }
50
51
    /**
52
     * {@inheritdoc}
53
     */
54
    protected static function getBundleClasses()
55
    {
56
        return [
57
            FrameworkBundle::class
58
        ];
59
    }
60
}
61