def check_indexes(self, params, page_num, indexes):
paginator = Paginator(*params)<EOL>if page_num == '<STR_LIT>':<EOL><INDENT>page_num = <NUM_LIT:1><EOL><DEDENT>elif page_num == '<STR_LIT>':<EOL><INDENT>page_num = paginator.num_pages<EOL><DEDENT>page = paginator.page(page_num)<EOL>start, end = indexes<EOL>msg = ("<STR_LIT>")<EOL>self.assertEqual(start, page.start_index(), msg % ('<STR_LIT>', page_num, start, page.start_index(), params))<EOL>self.assertEqual(end, page.end_index(), msg % ('<STR_LIT>', page_num, end, page.end_index(), params))<EOL>
Helper method that instantiates a Paginator object from the passed
params and then checks that the start and end indexes of the passed
page_num match those given as a 2-tuple in indexes.