Passed
Push — main ( 1cae26...7399d5 )
by Chema
03:24
created

ReadPhpConfigEventTest::setUp()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 3
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace GacelaTest\Unit\Framework\Event\ConfigReader;
6
7
use Gacela\Framework\Event\ConfigReader\ReadPhpConfigEvent;
8
use PHPUnit\Framework\TestCase;
9
10
final class ReadPhpConfigEventTest extends TestCase
11
{
12
    private ReadPhpConfigEvent $event;
13
14
    protected function setUp(): void
15
    {
16
        $this->event = new ReadPhpConfigEvent('absolute/path');
17
    }
18
19
    public function test_absolute_path(): void
20
    {
21
        self::assertSame(
22
            'absolute/path',
23
            $this->event->absolutePath(),
24
        );
25
    }
26
27
    public function test_to_string(): void
28
    {
29
        self::assertStringContainsString(
30
            '{absolutePath:"absolute/path"}',
31
            $this->event->toString(),
32
        );
33
    }
34
}
35