Total Complexity | 2 |
Total Lines | 44 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
11 | class BookTest extends TestCase |
||
12 | { |
||
13 | /** |
||
14 | * testCreateObject |
||
15 | * |
||
16 | * Construct object and verify that the object has the expected |
||
17 | * properties, use no arguments. |
||
18 | * |
||
19 | * @return void |
||
20 | */ |
||
21 | public function testCreateObject(): void |
||
22 | { |
||
23 | $book = new Book(); |
||
24 | $this->assertInstanceOf(Book::class, $book); |
||
25 | } |
||
26 | |||
27 | /** |
||
28 | * testSetAndGetMethods |
||
29 | * |
||
30 | * Test the set and get methods |
||
31 | * |
||
32 | * @return void |
||
33 | */ |
||
34 | public function testSetAndGetMethods(): void |
||
55 | } |
||
56 | } |
||
57 |
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.