Test Failed
Push — main ( 49ffe2...63a966 )
by Vedrana
07:24 queued 02:15
created

testConstructLibraryRepository()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 10
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 3
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 10
rs 10
1
<?php
2
3
namespace App\Tests\Repository;
4
5
use PHPUnit\Framework\TestCase;
6
7
use Doctrine\Persistence\ManagerRegistry;
8
use App\Repository\LibraryRepository;
9
10
/**
11
* Test that the LibraryRepository can be constructed properly.
12
*/
13
class LibraryRepositoryTest extends TestCase
14
{
15
    /**
16
     * Test that the LibraryRepository can be constructed properly.
17
     */
18
    public function testConstructLibraryRepository(): void
19
    {
20
        // Create a mock of the ManagerRegistry
21
22
        /** @var ManagerRegistry&\PHPUnit\Framework\MockObject\MockObject $registry */
23
        $registry = $this->createMock(ManagerRegistry::class);
24
25
        $repository = new LibraryRepository($registry);
26
27
        $this->assertInstanceOf("\App\Repository\LibraryRepository", $repository);
28
    }
29
}
30