

def testUnsortedSliceToEnd(self):
    session = self.session()
    qs = session.query(self.model)
    N = qs.count()
    self.assertTrue(N)
    q1 = (yield qs[0:])
    self.assertEqual(len(q1), N)
    q1 = (yield qs[3:])
    self.assertEqual(len(q1), (N - 3))
    for (id, q) in enumerate(q1, 4):
        self.assertEqual(q.id, id)

dataset/ETHPy150Open lsbardel/python-stdnet/tests/all/query/slice.py TestFilter.testUnsortedSliceToEnd/original