Commit 6607c9a2 authored by zhanhuasheng's avatar zhanhuasheng

新增用例 - 搜索

parent 2d26174d
......@@ -17,10 +17,10 @@ else:
page_num = int(tag_location / 10) + 1
setattr(tagData, 'page_num', int(page_num))
tag_room_select_sql = f'select * from `im_room` where `cate_id` = {tagData.brandId} and `status` = 1 and `site_id` = {tagData.shopId} and `is_ignore` = 0 and room_type != 2 and last_msg_uid != {tagData.userId}'
tag_room_select_sql = f'select * from `im_room` where `cate_id` = {tagData.brandId} and `status` = 1 and `site_id` = {tagData.shopId} and `is_ignore` = 0 and room_type != 2 and last_msg_uid != {tagData.userId} and from_id != ""'
tag_room_select_result = tagData.new_db_coon.select_one_value(sql=tag_room_select_sql)
room_id = tag_room_select_result['room_id']
user_id = tag_room_select_result['last_msg_uid']
user_id = tag_room_select_result['from_id']
setattr(tagData, 'room_id', str(room_id))
setattr(tagData, 'user_id', str(user_id))
tagData.new_db_coon.close_db()
\ No newline at end of file
......@@ -95,15 +95,15 @@ api10:
- eq: {"$.data.list[0].roomId": "${room_id}"}
- eq: {"$.data.list[0].searchMatchDimeType": 7}
#api11:
# title: 搜索用户标签
# url: /api/v1/chat/local/roomList
# method: post
# data: {"uid":"${userId}","uType":2,"platform":1,"siteIds":["${shopId}"],"status":1,"page":1,"pageSize":20,"sortName":"all","keyword":"${new_tag_name}","roomSearchExpArgs":{"searchDime":2,"searchId":""},"v":"${v}"}
# expected:
# - eq: {"$.code": 0}
# - eq: {"$.data.list[0].roomId": "${room_id}"}
# - eq: {"$.data.list[0].searchMatchDimeType": 12}
api11:
title: 搜索用户标签
url: /api/v1/chat/local/roomList
method: post
data: {"uid":"${userId}","uType":2,"platform":1,"siteIds":["${shopId}"],"status":1,"page":1,"pageSize":20,"sortName":"all","keyword":"${new_tag_name}","roomSearchExpArgs":{"searchDime":2,"searchId":""},"v":"${v}"}
expected:
- eq: {"$.code": 0}
- eq: {"$.data.list[0].roomId": "${room_id}"}
- eq: {"$.data.list[0].searchMatchDimeType": 12}
api12:
title: 搜索标签 - 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