aboutsummaryrefslogtreecommitdiff
path: root/tests/http/test_work.py
blob: c69118bd9ecd351f5e36e96e607489ef9adf4ef7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import pytest
from httpx import AsyncClient


class TestWork:

    @pytest.mark.anyio
    async def test_work(
        self,
        httpxclient: AsyncClient,
        hit_record,
        amt_assignment_id,
        amt_worker_id,
    ):
        client = httpxclient

        params = {
            "workerId": amt_worker_id,
            "assignmentId": amt_assignment_id,
            "hitId": hit_record.amt_hit_id,
        }
        res = await client.get("/work/", params=params)

        assert res.status_code == 200