helper.py 文件源码

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

项目:TestRewrite 作者: osqa-interns 项目源码 文件源码
def goto_calendar(self):
        """Return the teacher to the calendar dashboard."""
        print('Enter: goto_calendar')
        try:
            print('Try to return to the calendar')
            self.find(By.CSS_SELECTOR, '.course-name').click()
            print('Succeeded')
            self.page.wait_for_page_load()
        except:
            print('Failed, Try to return to the calendar using the Brand')
            try:
                self.find(
                    By.CSS_SELECTOR,
                    '.brand'
                ).click()
                print('Succeeded')
                self.page.wait_for_page_load()
            except:
                print('Failed, Load manually')
                self.get(
                    'https://' +
                    '/'.join(self.driver.current_url.split('/')[2:5])
                )
                pass
        print('Exit: goto_calendar')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号