| Conditions | 1 |
| Paths | 1 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 29 | public function testLimitOffsetWithExpression(): void |
||
| 30 | { |
||
| 31 | $query = (new Query($this->getConnection()))->from('customer')->select('id')->orderBy('id'); |
||
| 32 | |||
| 33 | // In MySQL limit and offset arguments must both be non negative integer constant |
||
| 34 | $query->limit(new Expression('2'))->offset(new Expression('1')); |
||
| 35 | |||
| 36 | $result = $query->column(); |
||
| 37 | |||
| 38 | $this->assertCount(2, $result); |
||
| 39 | $this->assertContains("2", $result); |
||
| 40 | $this->assertContains("3", $result); |
||
| 41 | $this->assertNotContains("1", $result); |
||
| 42 | } |
||
| 44 |