Commit 9f9a6ddd authored by 张慧's avatar 张慧

修复品类聚合页报错

parent 073ceccb
...@@ -97,12 +97,11 @@ class janus_request(BaseRequest): ...@@ -97,12 +97,11 @@ class janus_request(BaseRequest):
return self.api_send(self.data["service_promotion_related_service_data"]) return self.api_send(self.data["service_promotion_related_service_data"])
# 品类聚合页面商品列表 # 品类聚合页面商品列表
def tag_service(self, size, tag_ids, offset, tag_id, version, device_id): def tag_service(self, size, tag_ids, offset, version, device_id):
print("fgx") print("fgx")
self.params['size'] = size self.params['size'] = size
self.params['tag_ids'] = tag_ids self.params['tag_ids'] = tag_ids
self.params['offset'] = offset self.params['offset'] = offset
self.params['tag_id'] = tag_id
self.params['version'] = version self.params['version'] = version
self.params['device_id'] = device_id self.params['device_id'] = device_id
......
...@@ -92,7 +92,6 @@ tag_service: ...@@ -92,7 +92,6 @@ tag_service:
size: ${size} size: ${size}
tag_ids: ${tag_ids} tag_ids: ${tag_ids}
offset: ${offset} offset: ${offset}
tag_id: ${tag_id}
version: ${version} version: ${version}
device_id: ${device_id} device_id: ${device_id}
data: { } data: { }
......
...@@ -8,13 +8,13 @@ from all_backend_api.janus_request import janus_request ...@@ -8,13 +8,13 @@ from all_backend_api.janus_request import janus_request
class TestTagService: class TestTagService:
data = BaseRequest().api_load(path_setting.TAG_SERVICE) data = BaseRequest().api_load(path_setting.TAG_SERVICE)
tagservice_case, tagservice_data = get_ids(data, "tag_service") tag_service_case, tag_service_data = get_ids(data, "tag_service")
@pytest.mark.parametrize("param", tagservice_data, ids=tagservice_case) @pytest.mark.parametrize("param", tag_service_data, ids=tag_service_case)
def test_tag_service(self, param): def test_tag_service(self, param):
r = janus_request().tag_service(param["size"], param["tag_ids"], param["offset"], param["tag_id"], param["version"], param["device_id"]) r = janus_request().tag_service(param["size"], param["tag_ids"], param["offset"],
#print('feng=', r) param["version"], param["device_id"])
# print('feng=', r)
if r["error"] == 0: if r["error"] == 0:
assert r["error"] == param["assert"] assert r["error"] == param["assert"]
assert r["data"]["offset"] == param["offset"]
...@@ -6,7 +6,6 @@ tag_service: ...@@ -6,7 +6,6 @@ tag_service:
size: 10 size: 10
tag_ids: [] tag_ids: []
offset: 0 offset: 0
tag_id:
version: 7.43.0 version: 7.43.0
device_id: 869378034450718 device_id: 869378034450718
......
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