| Conditions | 1 |
| Paths | 1 |
| Total Lines | 28 |
| Code Lines | 21 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 14 | public function testDebugInfo(): void |
||
| 15 | { |
||
| 16 | /** @var MockObject&Query */ |
||
| 17 | $builder = $this->getMockBuilder(Query::class) |
||
| 18 | ->disableOriginalConstructor() |
||
| 19 | ->getMock(); |
||
| 20 | |||
| 21 | $paginator = (new Paginator($builder)) |
||
| 22 | ->orderBy('modified') |
||
| 23 | ->orderBy('id') |
||
| 24 | ->limit(3) |
||
| 25 | ->forward() |
||
| 26 | ->inclusive() |
||
| 27 | ->seekable(); |
||
| 28 | |||
| 29 | $actual = $paginator->__debugInfo(); |
||
| 30 | $this->assertEquals([ |
||
| 31 | 'query' => [ |
||
| 32 | 'orders' => [ |
||
| 33 | new Order('modified', 'asc'), |
||
| 34 | new Order('id', 'asc'), |
||
| 35 | ], |
||
| 36 | 'limit' => 3, |
||
| 37 | 'forward' => true, |
||
| 38 | 'inclusive' => true, |
||
| 39 | 'seekable' => true, |
||
| 40 | ], |
||
| 41 | ], $actual); |
||
| 42 | } |
||
| 44 |