Commit 68c06066 authored by aha's avatar aha

Merge branch 'cuixin_dev' into common_dev

parents f5462cba c89c5b57
......@@ -46,6 +46,12 @@ class living_request(BaseRequest):
self.params["version"] = version
return self.api_send(self.data["finish"])
#主播-分享按钮的点击
def get_live_info_audience(self,channel_id, version, device_id="97B6764B-2135-4761-9911-701C38CBC272"):
self.params["channel_id"] = channel_id
self.params["version"] = version
return self.api_send(self.data["get_live_info_audience"])
......@@ -53,4 +59,5 @@ if __name__ == '__main__':
(living_request().danmu_v2("739", "1"))
(living_request().pushlive_info("小冤家", "2021/04/22/1003/cef471cff5e6", "", "1", "1", "1"))
print (living_request().sendmsg("739","你好"))
print(living_request().finish("745", "746.0"))
\ No newline at end of file
print(living_request().finish("745", "746.0"))
print(living_request().get_live_info_audience("745", "7.46.0"))
\ No newline at end of file
......@@ -68,3 +68,14 @@ finish:
channel_id: ${channel_id}
json: {}
isLogin: 1
#主播-分享按钮的点击
get_live_info_audience:
method: GET
url: /api/live/get_live_info/audience
params:
channel_id: ${channel_id}
version: ${version}
data: {}
json: {}
isLogin: 1
......@@ -601,6 +601,10 @@ FINISH = os.path.join(BASE_DIR, "backend_auto/test_backend_data/live_data", "fin
MARK_LIVE_SERVICE_CONFIG = os.path.join(BASE_DIR, "backend_auto/all_backend_api", "janus_live_request.yaml")
MARK_LIVE_SERVICE = os.path.join(BASE_DIR, "backend_auto/test_backend_data/janus_live_data", "mark_live_service.yaml")
#主播-分享按钮的点击
GET_LIVE_INFO_AUDIENCE_CONFIG = os.path.join(BASE_DIR, "backend_auto/all_backend_api", "live_request.yaml")
GET_LIVE_INFO_AUDIENCE = os.path.join(BASE_DIR, "backend_auto/test_backend_data/live_data", "get_live_info_audience.yaml")
#免费招募活动详情
FREE_RECRUIT_DETAIL_CONFIG = os.path.join(BASE_DIR, "backend_auto/all_backend_api", "feed_request.yaml")
FREE_RECRUIT_DETAIL = os.path.join(BASE_DIR, "backend_auto/test_backend_data/feed_data", "free_recruit_detail.yaml")
......
import pytest
from ids_list import get_ids
import path_setting
from in_common.base_request import BaseRequest
from all_backend_api.live_request import living_request
class TestGetLiveInfoAudience:
data = BaseRequest().api_load(path_setting.GET_LIVE_INFO_AUDIENCE)
get_live_info_audience_case, get_live_info_audience_data = get_ids(data,"get_live_info_audience")
@pytest.mark.parametrize("param", get_live_info_audience_data, ids=get_live_info_audience_case)
def test_get_live_info_audience(self, param):
r = living_request().get_live_info_audience(param["channel_id"], param["version"])
print("主播分享直播间")
if r["error"] == 0:
assert r["data"]["channel_id"] == param["assert"]
assert r["data"]["share_data"]["wechat"]["title"][0:7] == param["assert0"]
assert r["data"]["share_data"]["wechatline"]["title"][0:7] == param["assert0"]
assert r["data"]["share_data"]["qq"]["title"][0:7] == param["assert0"]
\ No newline at end of file
get_live_info_audience:
#主播分享直播间
-
case: "主播分享直播间"
channel_id: "745"
version: "7.45.0"
assert: 745
assert0: 更美APP直播
\ No newline at end of file
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