本文整理汇总了Python中pages.treeherder.TreeherderPage.pin_using_spacebar方法的典型用法代码示例。如果您正苦于以下问题:Python TreeherderPage.pin_using_spacebar方法的具体用法?Python TreeherderPage.pin_using_spacebar怎么用?Python TreeherderPage.pin_using_spacebar使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pages.treeherder.TreeherderPage
的用法示例。
在下文中一共展示了TreeherderPage.pin_using_spacebar方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_clear_pinboard
# 需要导入模块: from pages.treeherder import TreeherderPage [as 别名]
# 或者: from pages.treeherder.TreeherderPage import pin_using_spacebar [as 别名]
def test_clear_pinboard(base_url, selenium):
"""Open treeherder page, pin a job and then clear the pinboard"""
page = TreeherderPage(selenium, base_url).open()
random.choice(page.all_jobs).click()
page.pin_using_spacebar()
assert 1 == len(page.pinboard.jobs)
page.pinboard.clear_pinboard()
assert page.pinboard.is_pinboard_open
assert 0 == len(page.pinboard.jobs)
示例2: test_pin_job
# 需要导入模块: from pages.treeherder import TreeherderPage [as 别名]
# 或者: from pages.treeherder.TreeherderPage import pin_using_spacebar [as 别名]
def test_pin_job(base_url, selenium):
"""Open treeherder page, select first job and pin it"""
page = TreeherderPage(selenium, base_url).open()
job = random.choice(page.all_jobs)
job.click()
assert 0 == len(page.pinboard.jobs)
page.pin_using_spacebar()
assert 1 == len(page.pinboard.jobs)
assert job.symbol == page.pinboard.selected_job.symbol
示例3: test_pin_a_bug
# 需要导入模块: from pages.treeherder import TreeherderPage [as 别名]
# 或者: from pages.treeherder.TreeherderPage import pin_using_spacebar [as 别名]
def test_pin_a_bug(base_url, selenium, new_user):
"""Open treeherder, log in, select unclassified job, pin job, add a bug, save and verify"""
page = TreeherderPage(selenium, base_url).open()
page.header.login(new_user['email'], new_user['password'])
assert page.header.is_user_logged_in
page.open_next_unclassified_failure()
assert not page.job_details.is_job_bug_visible
page.pin_using_spacebar()
bug_id = 1164485
page.pinboard.add_bug_to_pinned_job(bug_id)
page.pinboard.save_bug_to_pinboard()
message = page.notification_text
# Removed assert that Job Details displays bug number as it often requires a page refresh to display
assert "Bug association" in message