Conditions | 1 |
Paths | 1 |
Total Lines | 7 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
33 | public function testRenderDateTime(): void { |
||
34 | |||
35 | $obj = new TestDateTimeRendererTrait(); |
||
36 | |||
37 | $this->assertEquals("", $obj->renderDateTime(null)); |
||
|
|||
38 | $this->assertEquals("2019-01-14 18:15", $obj->renderDateTime(new DateTime("2019-01-14 18:15:00"))); |
||
39 | $this->assertEquals("14/01/2019 18h15", $obj->renderDateTime(new DateTime("2019-01-14 18:15:00"), "d/m/Y H\hi")); |
||
40 | } |
||
42 |
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.