'Waits for the tools to finish'

def library_wait(self, library_id, cntrller='library_admin', maxiter=90):

    count = 0
    sleep_amount = 1
    while (count < maxiter):
        count += 1
        self.visit_url(('%s/library_common/browse_library?cntrller=%s&id=%s' % (self.url, cntrller, library_id)))
        page = tc.browser.get_html()
        if (page.find('<!--    running:    do    not    change    this    comment,    used    by    TwillTestCase.library_wait    -->') > (-1)):
            time.sleep(sleep_amount)
            sleep_amount += 1
        else:
            break
    self.assertNotEqual(count, maxiter)
