@@ -0,0 +1,17 @@
+from hytest import *
+from lib.webapi import apimgr
+class c1:
+ #测试用例名称
+ name='推送设置获取'
+ #测试步骤
+ def teststeps(self):
+ INFO('测试步骤')
+ STEP(1,'第一步调用函数') #会出现在测试报告中
+ r = apimgr.push_settings()
+ res = r.json()
+ INFO(res)
+ actural = res['error_code']
+ actural1 = res['data']['interested']['interested']
+ STEP(2,'第二步设置检查点')
+ #设置检查点
+ CHECK_POINT('检查推送设置获取是否正常',actural ==0 and actural1 ==1)
@@ -1978,6 +1978,15 @@ class APIMgr():
response = self.s.post(f"{cfg.target_host}/jyapi/jybx/subscribe/getUser", headers=headers, json=json)
return response
+ """推送设置获取"""
+ def push_settings(self):
+ headers = GSTORE['headers']
+ params = {
+ "t": "1752489527091"
+ }
+ response = self.s.post(f"{cfg.target_host}/jyapi/jybx/subscribe/getPushSet", headers=headers, params=params)
+ return response
+
apimgr = APIMgr()