Skip to content

Commit

Permalink
Fix pytest problem
Browse files Browse the repository at this point in the history
  • Loading branch information
zhiltsov-max committed Oct 5, 2024
1 parent b4232dc commit ee9e930
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions tests/python/rest_api/test_quality_control.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,7 @@ def create_gt_job(self, user, task_id):
return job

@pytest.fixture(scope="class")
@classmethod
def find_sandbox_task(cls, tasks, jobs, users, is_task_staff):
def find_sandbox_task(self, tasks, jobs, users, is_task_staff):
def _find(
is_staff: bool, *, has_gt_jobs: Optional[bool] = None
) -> Tuple[Dict[str, Any], Dict[str, Any]]:
Expand Down Expand Up @@ -111,13 +110,11 @@ def _find(
return _find

@pytest.fixture(scope="class")
@classmethod
def find_sandbox_task_without_gt(cls, find_sandbox_task):
def find_sandbox_task_without_gt(self, find_sandbox_task):
return partial(find_sandbox_task, has_gt_jobs=False)

@pytest.fixture(scope="class")
@classmethod
def find_org_task(cls, tasks, jobs, users, is_org_member, is_task_staff):
def find_org_task(self, tasks, jobs, users, is_org_member, is_task_staff):
def _find(
is_staff: bool, user_org_role: str, *, has_gt_jobs: Optional[bool] = None
) -> Tuple[Dict[str, Any], Dict[str, Any]]:
Expand Down Expand Up @@ -154,8 +151,7 @@ def _find(
return _find

@pytest.fixture(scope="class")
@classmethod
def find_org_task_without_gt(cls, find_org_task):
def find_org_task_without_gt(self, find_org_task):
return partial(find_org_task, has_gt_jobs=False)

_default_sandbox_cases = ("is_staff, allow", [(True, True), (False, False)])
Expand Down

0 comments on commit ee9e930

Please sign in to comment.