本文整理匯總了Python中Utils.InitCase.select_menu方法的典型用法代碼示例。如果您正苦於以下問題:Python InitCase.select_menu方法的具體用法?Python InitCase.select_menu怎麽用?Python InitCase.select_menu使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Utils.InitCase
的用法示例。
在下文中一共展示了InitCase.select_menu方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: test
# 需要導入模塊: from Utils import InitCase [as 別名]
# 或者: from Utils.InitCase import select_menu [as 別名]
def test(self):
self.verificationErrors = []
Config.find_element(Config.openSettings).click()
time.sleep(1)
self.user = Config.find_element(Config.settings_email).text
InitCase.init_case(menu="ALL", taskNo=0)
InitCase.init_case(menu="ALL", view="date", taskOption="share")
Config.find_element(Config.sharing_inputEmail).clear()
Config.find_element(Config.sharing_inputEmail).send_keys(self.other_user())
Config.wait_for_element(Config.sharing_inputEmailDone)
time.sleep(1)
Config.find_element(Config.sharing_commitEmailButton).click()
Config.wait_for_element(Config.sharing_sendInvites)
Config.find_element(Config.sharing_sendInvites).click()
Config.wait_for_element(Config.sharing_inviteOverlay, present=False)
ChangeUser.change_user(self.other_user())
self.user = self.other_user()
Config.wait_for_element(Config.sharingInvitation)
try: self.assertEqual(Config.find_element(Config.sharingInvitation_title).text, "SHARED TASK")
except AssertionError as e: self.verificationErrors.append(str(e))
Config.find_element(Config.sharingInvitation_decline).click()
Config.sync()
InitCase.select_menu("ALL")
try: self.assertFalse(Config.find_element(Config.taskShare).is_displayed())
except AssertionError as e: self.verificationErrors.append(str(e))
ChangeUser.change_user(self.other_user())
self.user = self.other_user()
InitCase.init_case(menu="ALL", taskOption="share")
try: self.assertEqual(Config.find_element(Config.sharing_memberBadgeByEmail, self.other_user()).get_attribute("data-status"), "REJECTED")
except AssertionError as e: self.verificationErrors.append(e)
Config.find_element(Config.sharing_memberBadgeByEmail, self.other_user()).click()
ActionChains(Config.get_driver()).move_to_element(Config.find_element(Config.sharing_memberPopup)).perform()
try: self.assertEqual(Config.find_element(Config.sharing_badgeStatus).text, "Rejected Invitation")
except AssertionError as e: self.verificationErrors.append(e)
self.assertEqual([], self.verificationErrors)