import pytest

from ids_list import get_ids
import path_setting
from in_common.base_request import BaseRequest
from all_backend_api.oneimage_request import oneimage_request


class TestShareV4:
    """
    测颜值结果页，分享结果
    """
    data = BaseRequest().api_load(path_setting.ONEIMAGE_SHARE_V4_DATA)
    sharev4_case, sharev4_data = get_ids(data, "share_v4")

    # @pytest.mark.skip("跳过，测颜值结果v4，目前数据是线上的-------------------")
    @pytest.mark.parametrize("param",sharev4_data,ids=sharev4_case)
    def test_share_v4(self,param):
        r = oneimage_request().share_v4(param["version"], param["face_id"])
        assert r["error"] == 0


