Переглянути джерело

app新用户报表提交/跳过

jialuyao 9 місяців тому
батько
коміт
3af42e837c
2 змінених файлів з 32 додано та 1 видалено
  1. 17 0
      cases/app/登录/留资/app_new_uer_sales.py
  2. 15 1
      lib/webapi.py

+ 17 - 0
cases/app/登录/留资/app_new_uer_sales.py

@@ -0,0 +1,17 @@
+from hytest import *
+from lib.webapi import apimgr
+
+class c1:
+    name = 'app新用户报表提交/跳过'
+    def teststeps(self):
+        INFO('测试步骤')
+        STEP(1, '第一步调用函数')
+        res=apimgr.app_new_uer_sales()
+        r = res.json()
+        INFO(r)
+        actural=r['error_code']
+        actural1=r['error_msg']
+        # INFO(length)
+        STEP(2, '第二步设置检查点')
+        # 设置检查点
+        CHECK_POINT('检查用户中台接口是否正常',  actural == 0 and actural1 == "保存成功")

+ 15 - 1
lib/webapi.py

@@ -941,7 +941,21 @@ class APIMgr():
         }
         response = self.s.post(f"{cfg.target_host}/bigmember/decision/decInfo", headers=headers, json=json)
         return response
-
+    #app新用户报表提交/跳过
+    def app_new_uer_sales(self):
+        headers = GSTORE['headers']
+        json = {
+            "area##business":"广州,北京",
+            "company":"剑鱼",
+            "department":"其他",
+            "model##business":"投标方",
+            "position":"职员",
+            "product##engineering":"交通设施,外工程",
+            "product##product":"化工用品包装材料,机电设备",
+            "product##seryice":"广告传媒,餐饮服务"
+        }
+        response = self.s.post(f"{cfg.target_host_app}/salesLeads/appNewUerSales", headers=headers, json=json)
+        return response
 
 apimgr = APIMgr()