clipbucket_driver.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:ansible-role-clipbucket 作者: mtlynch 项目源码 文件源码
def do_check_modules(self):
        logger.info('Checking ClipBucket modules')
        self.get('/admin_area/cb_mod_check.php')

        for module_element in self._driver.find_elements_by_class_name('well'):
            ui.WebDriverWait(
                self._driver, TIMEOUT).until(
                expected_conditions.visibility_of(module_element))
            try:
                alert_element = module_element.find_element_by_class_name(
                    'alert')
                if alert_element:
                    raise ClipBucketModuleError(alert_element.text)
            except exceptions.NoSuchElementException:
                # Lack of alert is good: the module is installed correctly.
                continue
        logger.info('Module check complete')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号