def drag_scroll_bar(step, top_or_bottom): with AssertContextManager(step): offsety = 60 if top_or_bottom == "bottom": bo.drag_scroll_to_bottom(world.browser, offsety) else: bo.drag_scroll_to_top(world.browser, -int(offsety))
def check_next_chunk_loaded(step, offsety, times, num): get_url(world.browser, "http://localhost:4200/lazy-loaded-loans?totalCount=" + str(num)) bo.drag_scroll_by_css_with_times(world.browser, offsety, times) assert len(get_mb_request()) == int(times) + 2 bo.drag_scroll_to_top(world.browser, -int(offsety)) assert len(get_mb_request()) == int(times) + 2