Completed
Push — master ( fe759b...532b8b )
by
unknown
02:54 queued 11s
created

TruncateControllerTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 3
dl 0
loc 11
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A testTruncate() 0 8 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of the Sonata Project package.
7
 *
8
 * (c) Thomas Rabaix <[email protected]>
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace Sonata\MediaBundle\Tests\Functional\Controller;
15
16
use PHPUnit\Framework\TestCase;
17
use Sonata\MediaBundle\Tests\App\AppKernel;
18
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
19
use Symfony\Component\HttpFoundation\Request;
20
use Symfony\Component\HttpFoundation\Response;
21
22
final class TruncateControllerTest extends TestCase
23
{
24
    public function testTruncate(): void
25
    {
26
        $client = new KernelBrowser(new AppKernel());
27
        $client->request(Request::METHOD_GET, '/u_truncate_test');
28
29
        $this->assertSame(Response::HTTP_OK, $client->getResponse()->getStatusCode());
30
        $this->assertSame('test', $client->getResponse()->getContent());
31
    }
32
}
33