Commit bd410493 authored by 刘丙寅's avatar 刘丙寅

修改用例问题

parent a990675b
...@@ -154,25 +154,25 @@ if __name__ == "__main__": ...@@ -154,25 +154,25 @@ if __name__ == "__main__":
#发给谁的邮箱 #发给谁的邮箱
receiver = ["liubingyin@igengmei.com", "chenxiangxiang@igengmei.com"] receiver = ["liubingyin@igengmei.com", "chenxiangxiang@igengmei.com"]
send_mail(sender, psw, receiver, smtp_server, report_file, port) # 4最后一步发送报告 send_mail(sender, psw, receiver, smtp_server, report_file, port) # 4最后一步发送报告
# dd_url = "https://oapi.dingtalk.com/robot/send?access_token=4aa12245f7b6c273dde43c4a547b386cd12dc59f22a475f2efbd494094be15b9" dd_url = "https://oapi.dingtalk.com/robot/send?access_token=4aa12245f7b6c273dde43c4a547b386cd12dc59f22a475f2efbd494094be15b9"
# text = "监控报警:接口出现异常,请查看邮件排查问题" text = "监控报警:接口出现异常,请查看邮件排查问题"
# json_text = { json_text = {
# "msgtype": "text", "msgtype": "text",
# "at": { "at": {
# "atMobiles": [ "atMobiles": [
# # 变为所有人 这里要改 # 变为所有人 这里要改
# "all" "all"
# ], ],
# # 变为true 就会@所有人 # 变为true 就会@所有人
# #"isAtAll": False #"isAtAll": False
# "isAtAll": True "isAtAll": True
# }, },
# "text": { "text": {
# "content": text "content": text
# } }
# } }
#
# requests.post(url=dd_url, json=json_text, verify=False) requests.post(url=dd_url, json=json_text, verify=False)
else: else:
print("无问题 不发送测试报告哦") print("无问题 不发送测试报告哦")
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