FakerFactoryTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 2
dl 0
loc 22
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A testCreateFaker() 0 5 1
A testIfFakerFactoryAlwayReturnsTheSameObject() 0 7 1
1
<?php
2
declare(strict_types=1);
3
4
namespace TildBJ\Seeder\Tests\Unit\Factory;
5
6
use Nimut\TestingFramework\TestCase\UnitTestCase;
7
8
/**
9
 * Class FakerFactoryTest
10
 */
11
class FakerFactoryTest extends UnitTestCase
12
{
13
    /**
14
     * @test
15
     */
16
    public function testCreateFaker()
17
    {
18
        $instance = \TildBJ\Seeder\Factory\FakerFactory::createFaker();
19
        $this->assertInstanceOf(\TildBJ\Seeder\Faker::class, $instance);
20
    }
21
22
    /**
23
     * @test
24
     */
25
    public function testIfFakerFactoryAlwayReturnsTheSameObject()
26
    {
27
        $firstInstance = \TildBJ\Seeder\Factory\FakerFactory::createFaker();
28
        $secondInstance = \TildBJ\Seeder\Factory\FakerFactory::createFaker();
29
30
        $this->assertSame($firstInstance, $secondInstance);
31
    }
32
}
33