fix: Lint fixes of core and repositories tests
All checks were successful
Backend CI / lint (push) Successful in 9m26s
Backend CI / test (push) Successful in 4m24s

This commit is contained in:
JSC
2025-08-01 09:17:20 +02:00
parent 389cfe2d6a
commit dc29915fbc
8 changed files with 135 additions and 88 deletions

View File

@@ -1,4 +1,5 @@
"""Tests for extraction repository."""
# ruff: noqa: ANN001, ANN201
from unittest.mock import AsyncMock, Mock
@@ -8,6 +9,9 @@ from sqlmodel.ext.asyncio.session import AsyncSession
from app.models.extraction import Extraction
from app.repositories.extraction import ExtractionRepository
# Constants
TEST_SOUND_ID = 42
class TestExtractionRepository:
"""Test extraction repository."""
@@ -123,6 +127,6 @@ class TestExtractionRepository:
result = await extraction_repo.update(extraction, update_data)
assert result.status == "completed"
assert result.sound_id == 42
assert result.sound_id == TEST_SOUND_ID
extraction_repo.session.commit.assert_called_once()
extraction_repo.session.refresh.assert_called_once_with(extraction)