Commit 4f7530bb by zhangchunyao

code update 201907231731

parent 8af5c5e2
......@@ -13,7 +13,7 @@ qaTeamWebhook = 'https://oapi.dingtalk.com/robot/send?access_token=2656a52b44f1e
qaTeamDing = DingtalkChatbot(qaTeamWebhook)
runTime = time.strftime('%Y-%m-%d %H:%M:%S')
def resultText(reporturl):
def resultTextFalse(reporturl):
#path = 'D:/workSpace/Python_workspace/apitestunit.xls'
path = '/opt/apitest/apiAutoByJenkins/repot/apitest.xls'
readExp = Reader()
......@@ -21,8 +21,11 @@ def resultText(reporturl):
expMsg = '\n'.join(arrExpSingle)
qaTeamDing.send_text(msg = "接口自动化执行异常结果\n执行时间:"+ runTime+ "\n执行异常接口列表:\n"+expMsg+"\n详细结果地址:"+reporturl)
def resultTextPass(reporturl):
qaTeamDing.send_text(msg = "接口自动化执行无误\n执行时间:"+ runTime+ "\n详细结果地址:"+reporturl)
def msgSend(passrate,reporturl):
if passrate!=100:
resultText(reporturl)
if float(passrate)==100.00:
resultTextPass(reporturl)
else :
pass
\ No newline at end of file
resultTextFalse(reporturl)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment