浏览代码

推送数据浏览状态修改-大会员用户

liuyali@topnet.net.cn 1 周之前
父节点
当前提交
a137767809
共有 2 个文件被更改,包括 36 次插入2 次删除
  1. 25 0
      cases/pc/登录功能/订阅/pushdata_setread_mtype.py
  2. 11 2
      lib/webapi.py

+ 25 - 0
cases/pc/登录功能/订阅/pushdata_setread_mtype.py

@@ -0,0 +1,25 @@
+from hytest import *
+from lib.webapi import apimgr
+class c1:
+    name = '大会员用户推送数据浏览状态修改'
+    def setup(self):
+        INFO('切换用户身份到营销测试企业下')
+        apimgr.Identity_list(3)
+        apimgr.Identity_switch()
+
+    def teardown(self):
+        INFO('将用户切回到闫培珠新版商机管理企业')
+        apimgr.Identity_list(1)
+        apimgr.Identity_switch()
+    def teststeps(self):
+        INFO('测试步骤')
+        STEP(1, '第一步调用函数')
+        res = apimgr.pushdata_setread_mtype()
+        actual = res.json()
+        INFO(actual)
+        error_code = actual["error_code"]
+        STEP(2, '第二步设置检查点')
+        # 设置检查点
+        CHECK_POINT('检查推送数据浏览状态修改-大会员用户接口是否正常',error_code == 0)
+
+

+ 11 - 2
lib/webapi.py

@@ -1,8 +1,8 @@
 import json
 import requests
 from hytest.common import *
-#from pandas.io.formats.style import properties_args
-#from sympy.physics.vector.printing import params
+from pandas.io.formats.style import properties_args
+from sympy.physics.vector.printing import params
 
 from cfg import cfg
 from bs4 import BeautifulSoup
@@ -2153,6 +2153,15 @@ class APIMgr():
         }
         response = self.s.post(f"{cfg.target_host}/jyapi/jybx/subscribe/vType/setRead",headers=headers, params=params)
         return response
+    # 推送数据浏览状态修改-大会员用户
+    def pushdata_setread_mtype(self):
+        headers = GSTORE['headers']
+        params = {
+            "vsid": "4734479853",
+            "isEnt": "false"
+        }
+        response = self.s.post(f"{cfg.target_host}/jyapi/jybx/subscribe/mType/setRead", headers=headers, params=params)
+        return response