''' @author: liudixuan @software: SeleniumTest @file: missfresh_my_invatation.py @time: 2020/3/25 17:38 @desc: ''' from pages.invite_page import InviPage from cases.base_case import * from conmon.logger import Logger logger = Logger().logger class MyInvite(BaseCase): ''' 邀请得现金模块 ''' def test_my_invite(self): ''' MRYX-ST-FU-008;验证跳转邀请得现金成功 :return: ''' weixin_activity = 'com.tencent.mm.ui.transmit.SelectConversationUI' # 去到我的模块 mp = MyPage(self.driver) # 向下滑动 self.driver.swipe(314, 1187, 314, 227) #去到邀请得现金 mp.invite_button_click()
''' @author: liudixuan @software: SeleniumTest @file: run.py @time: 2020/3/26 21:24 @desc: ''' import unittest from conmon.get_path import * import time from BeautifulReport import BeautifulReport from conmon.logger import Logger import unittest from conmon.get_path import * logger = Logger().logger discover = unittest.defaultTestLoader.discover(CASE_PATH, pattern="missfresh_my_*.py") _time = time.strftime("%Y-%m-%d %H_%M_%S") filename = "missfresh_{}.html".format(_time) logger.info(filename) BeautifulReport(discover).report(description='missfresh-tests', report_dir='report', filename=filename)