Total Complexity | 4 |
Total Lines | 27 |
Duplicated Lines | 0 % |
Coverage | 93.33% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
15 | final class NullValueTest extends TestCase |
||
16 | { |
||
17 | private NullValue $nullValue; |
||
18 | |||
19 | 1 | public function testToNative(): void |
|
20 | { |
||
21 | 1 | $this->assertNull($this->nullValue->toNative()); |
|
|
|||
22 | 1 | $this->assertNull(NullValue::fromNative(null)->toNative()); |
|
23 | 1 | $this->assertNull(NullValue::fromNative('')->toNative()); |
|
24 | |||
25 | 1 | $this->expectException(InvalidArgumentException::class); |
|
26 | 1 | NullValue::fromNative('xyz'); |
|
27 | } |
||
28 | |||
29 | 1 | public function testEquals(): void |
|
32 | 1 | } |
|
33 | |||
34 | 1 | public function testToString(): void |
|
37 | 1 | } |
|
38 | |||
39 | 3 | protected function setUp(): void |
|
44 |
This check looks for function or method calls that always return null and whose return value is used.
The method
getObject()
can return nothing but null, so it makes no sense to use the return value.The reason is most likely that a function or method is imcomplete or has been reduced for debug purposes.