本文整理汇总了Python中gaiatest.apps.calendar.app.Calendar.wait_to_be_displayed方法的典型用法代码示例。如果您正苦于以下问题:Python Calendar.wait_to_be_displayed方法的具体用法?Python Calendar.wait_to_be_displayed怎么用?Python Calendar.wait_to_be_displayed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类gaiatest.apps.calendar.app.Calendar
的用法示例。
在下文中一共展示了Calendar.wait_to_be_displayed方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: TestCardsView
# 需要导入模块: from gaiatest.apps.calendar.app import Calendar [as 别名]
# 或者: from gaiatest.apps.calendar.app.Calendar import wait_to_be_displayed [as 别名]
class TestCardsView(GaiaTestCase):
def setUp(self):
GaiaTestCase.setUp(self)
self.calendar = Calendar(self.marionette)
self.calendar.launch()
self.clock = Clock(self.marionette)
self.clock.launch()
# Switch to top level frame before starting the test
self.marionette.switch_to_frame()
def test_that_app_can_be_launched_from_cards_view(self):
"""
https://moztrap.mozilla.org/manage/case/2462/
"""
cards_view = CardsView(self.marionette)
self.assertFalse(cards_view.is_displayed, 'Cards view not expected to be visible')
# Pull up the cards view
self.device.hold_home_button()
cards_view.wait_for_cards_view()
# Wait for first app ready
cards_view.cards[1].wait_for_centered()
self.assertIn(cards_view.cards[0].manifest_url, self.calendar.manifest_url)
self.assertTrue(cards_view.cards[0].is_displayed,
'%s app should be present in cards view' % cards_view.cards[1].title)
self.assertIn(cards_view.cards[1].manifest_url, self.clock.manifest_url)
self.assertTrue(cards_view.cards[1].is_displayed,
'%s app should be present in cards view' % cards_view.cards[1].title)
cards_view.swipe_to_previous_app()
# Wait for previous app ready
cards_view.cards[0].wait_for_centered()
cards_view.cards[0].tap()
cards_view.wait_for_cards_view_not_displayed()
self.calendar.wait_to_be_displayed()