import pytest

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



class TestVote:
    data = BaseRequest().api_load(path_setting.TOPIC_VOTE)
    topic_vote_case, topic_vote_data = get_ids(data, "topic_vote")

    @pytest.mark.skip
    @pytest.mark.parametrize("param", topic_vote_data, ids=topic_vote_case)
    def test_vote(self, param):
        r = topic_request().topic_vote(param["topic_id"])
        print("返回结果", r)
        assert r["error"] == 0








