Test the interaction between limit and limit/offset
(self, connection)
| 992 | |
| 993 | @testing.requires.offset |
| 994 | def test_select_distinct_limit_offset(self, connection): |
| 995 | """Test the interaction between limit and limit/offset""" |
| 996 | |
| 997 | users, addresses = self.tables("users", "addresses") |
| 998 | |
| 999 | r = connection.execute( |
| 1000 | select(addresses.c.address) |
| 1001 | .order_by(addresses.c.address) |
| 1002 | .distinct() |
| 1003 | .offset(2) |
| 1004 | .limit(3) |
| 1005 | ).fetchall() |
| 1006 | self.assert_(len(r) == 3, repr(r)) |
| 1007 | self.assert_(r[0] != r[1] and r[1] != r[2], repr(r)) |
| 1008 | |
| 1009 | |
| 1010 | class CompoundTest(fixtures.TablesTest): |