def get_expected_votes_data(user, project=None):
    """
    Return the expect data for the votes tests
    :param user: user
    :param project: project
    :retuen: expected data dicts for the specified user and/or project
    """
    data = dict(
        user_1=[
            dict(
                topic="topic_aaa",
                project_name="project_a",
                vote_count=10,
                last_vote="1111",
            ),
            dict(
                topic="topic_bbb",
                project_name="project_a",
                vote_count=20,
                last_vote="2222",
            ),
            dict(
                topic="topic_ccc",
                project_name="project_b",
                vote_count=30,
                last_vote="3333",
                hidden=True,
            ),
        ],
        user_2=[
            dict(
                topic="topic_ddd",
                project_name="project_c",
                vote_count=40,
                last_vote="4444",
            ),
        ],
    )

    if user in data:
        if not project:
            result = data[user]
        else:
            result = [x for x in data[user] if x["project_name"] == project]
    else:
        return []

    return sorted(result, key=lambda x: x["vote_count"], reverse=True)