Conditions | 1 |
Paths | 1 |
Total Lines | 21 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
64 | public function testGetSlice() |
||
65 | { |
||
66 | $offset = 14; |
||
67 | $length = 20; |
||
68 | $slice = new \ArrayObject(); |
||
69 | |||
70 | $this->query |
||
71 | ->expects($this->once()) |
||
72 | ->method('limit') |
||
73 | ->with($length); |
||
74 | $this->query |
||
75 | ->expects($this->once()) |
||
76 | ->method('offset') |
||
77 | ->with($offset); |
||
78 | $this->query |
||
79 | ->expects($this->once()) |
||
80 | ->method('find') |
||
81 | ->will($this->returnValue($slice)); |
||
82 | |||
83 | $this->assertSame($slice, $this->adapter->getSlice($offset, $length)); |
||
84 | } |
||
85 | } |
||
86 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: