示例#1
0
 def test3(self):
   p = Pagination(1, 10, 100)
   l = list(p.iter_pages())
   self.assertEquals([1, 2, 3, 4, 5, None, 9, 10], l)
示例#2
0
 def test4(self):
   p = Pagination(10, 10, 100)
   l = list(p.iter_pages())
   self.assertEquals([1, 2, None, 8, 9, 10], l)
示例#3
0
 def test2(self):
   p = Pagination(1, 10, 20)
   l = list(p.iter_pages())
   self.assertEquals([1, 2], l)