Conditions | 1 |
Paths | 1 |
Total Lines | 18 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
13 | public function testJobClass() |
||
14 | { |
||
15 | $stub = $this->getMockForAbstractClass('ResqueBundle\Resque\Job', [[1, 2, 3]]); |
||
16 | |||
17 | // test init correctly |
||
18 | $this->assertContains('Job', $stub->getName()); |
||
19 | $this->assertEquals('default', $stub->queue); |
||
|
|||
20 | $this->assertEquals([1, 2, 3], $stub->args); |
||
21 | |||
22 | |||
23 | // test that perform calls run |
||
24 | $stub |
||
25 | ->expects($this->once()) |
||
26 | ->method('run'); |
||
27 | |||
28 | $stub->perform(); |
||
29 | |||
30 | } |
||
31 | } |
||
32 |
If you access a property on an interface, you most likely code against a concrete implementation of the interface.
Available Fixes
Adding an additional type check:
Changing the type hint: