Commit 16280871 authored by 张伟男's avatar 张伟男

导出邮件,增加用例

parent 9695a899
......@@ -68,8 +68,9 @@ class achelous_request(BaseRequest):
# OM后台-商业分类管理,后台分类(工业)
def industry_search(self, tag_system_type, tag_name, is_online, is_display, is_move, page, size):
def industry_search(self, tag_system_type,tag_id, tag_name, is_online, is_display, is_move, page, size):
self.params["tag_system_type"] = tag_system_type
self.params["tag_id"] = tag_id
self.params["tag_name"] = tag_name
self.params["is_online"] = is_online
self.params["is_display"] = is_display
......@@ -96,6 +97,9 @@ class achelous_request(BaseRequest):
self.params["is_move"] = is_move
return self.api_send(self.data["catalog_add"])
def category_export_catalog_datas(self):
return self.api_send(self.data["category_export_catalog_datas"])
if __name__ == "__main__":
......@@ -105,4 +109,5 @@ if __name__ == "__main__":
# print(achelous_request().special_list('1', '10', '', '', '', '', '', '1', '0', '', ''))
# print(achelous_request().industry_search(1,"口腔","all","all","all",1,10))
# print(achelous_request().category_ordering(1002463,1,1,2))
print(achelous_request().catalog_add(1, "自动化接口测试添加2", 15510, [], "false", "false", "false"))
\ No newline at end of file
# print(achelous_request().catalog_add(1, "自动化接口测试添加2", 15510, [], "false", "false", "false"))
print(achelous_request().category_export_catalog_datas())
\ No newline at end of file
......@@ -99,6 +99,7 @@ industry_search:
params:
tag_system_type: ${tag_system_type}
tag_name: ${tag_name}
tag_id: ${tag_id}
is_online: ${is_online}
is_display: ${is_display}
is_move: ${is_move}
......@@ -136,3 +137,12 @@ catalog_add:
is_move: ${is_move}
json: {}
isLogin: 1
#OM后台-商业分类管理,邮件导出
category_export_catalog_datas:
method: GET
url: /achelous/api/category/export_catalog_datas
params: {}
data: {}
json: {}
isLogin: 1
\ No newline at end of file
import pytest
import path_setting
from all_om_api.achelous_request import achelous_request
from ids_list import get_ids
from in_common.base_request import BaseRequest
class TestCatrgoryExportCatlogDatas:
def test_industry_search(self):
r = achelous_request().category_export_catalog_datas()
print(r)
assert r["msg"] == "success"
assert r["data"] is True
assert r["code"] == 0
......@@ -12,8 +12,8 @@ class TestIndustrySearch:
@pytest.mark.parametrize("param", industry_search_data, ids= industry_search_case)
def test_industry_search(self, param):
r = achelous_request().industry_search(param["tag_system_type"], param["tag_name"],param["is_online"], param["is_display"], param["is_move"], param["page"], param["size"])
# print(r)
if r["code"] == 0 and r["msg"] == "success":
r = achelous_request().industry_search(param["tag_system_type"], param["tag_id"],param["tag_name"],param["is_online"], param["is_display"], param["is_move"], param["page"], param["size"])
print(r)
assert r["code"] == 0
assert len(r["data"]["data"]) > 0
#OM后台-商业分类管理,后台分类(工业)
industry_search:
-
case: '搜索口腔标签'
case: '搜索标签-名称模糊搜索'
tag_system_type: 1
tag_name: "白"
tag_id: ""
is_online: "all"
is_display: "all"
is_move: "all"
page: 1
size: 10
-
case: '搜索标签-根据id'
tag_system_type: 1
tag_name: ""
tag_id: 1002542
is_online: "all"
is_display: "all"
is_move: "all"
......
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