本文整理汇总了Python中gaiatest.apps.clock.app.Clock.tap_digital_display方法的典型用法代码示例。如果您正苦于以下问题:Python Clock.tap_digital_display方法的具体用法?Python Clock.tap_digital_display怎么用?Python Clock.tap_digital_display使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类gaiatest.apps.clock.app.Clock
的用法示例。
在下文中一共展示了Clock.tap_digital_display方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: TestClockSwitchClockType
# 需要导入模块: from gaiatest.apps.clock.app import Clock [as 别名]
# 或者: from gaiatest.apps.clock.app.Clock import tap_digital_display [as 别名]
class TestClockSwitchClockType(GaiaTestCase):
def setUp(self):
GaiaTestCase.setUp(self)
self.clock = Clock(self.marionette)
self.clock.launch()
def test_clock_switch_clock_type_and_show_time_date(self):
""" Switch the clock type and show time and date
https://moztrap.mozilla.org/manage/case/1770
https://moztrap.mozilla.org/manage/case/1771
"""
# switch to digital clock and check the date, time, state for digital clock
self.clock.tap_analog_display()
self.assertTrue(self.clock.is_digital_clock_displayed, "The digital clock should be displayed.")
self.assertTrue(self.clock.is_day_and_date_displayed, "The date of digital clock should be displayed.")
self.assertTrue(self.clock.is_24_hour_state_displayed, "The hour24-state of digital clock should be displayed.")
# switch to analog clock and check the date, time for analog clock
self.clock.tap_digital_display()
self.assertTrue(self.clock.is_analog_clock_displayed, "The analog clock should be displayed.")
self.assertTrue(self.clock.is_day_and_date_displayed, "The date of digital clock should be displayed.")
self.assertFalse(self.clock.is_24_hour_state_displayed, "The hour24-state of digital clock should be displayed.")