Refactor imports across multiple files to improve code organization and readability.
All checks were successful
CI pipeline / Test & Code Quality (push) Successful in 34s
All checks were successful
CI pipeline / Test & Code Quality (push) Successful in 34s
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
from unittest.mock import AsyncMock, MagicMock, patch
|
||||
|
||||
import pytest
|
||||
|
||||
from helper_bot.handlers.private.services import AutoModerationService, BotSettings
|
||||
|
||||
|
||||
@@ -108,9 +109,7 @@ class TestAutoModerationService:
|
||||
assert result == "manual"
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_check_auto_action_publish_at_exact_threshold(
|
||||
self, service, mock_db
|
||||
):
|
||||
async def test_check_auto_action_publish_at_exact_threshold(self, service, mock_db):
|
||||
"""Тест: возвращает publish когда score равен порогу."""
|
||||
mock_db.get_auto_moderation_settings.return_value = {
|
||||
"auto_publish_enabled": True,
|
||||
@@ -124,9 +123,7 @@ class TestAutoModerationService:
|
||||
assert result == "publish"
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_check_auto_action_decline_at_exact_threshold(
|
||||
self, service, mock_db
|
||||
):
|
||||
async def test_check_auto_action_decline_at_exact_threshold(self, service, mock_db):
|
||||
"""Тест: возвращает decline когда score равен порогу."""
|
||||
mock_db.get_auto_moderation_settings.return_value = {
|
||||
"auto_publish_enabled": False,
|
||||
|
||||
Reference in New Issue
Block a user