mirror of
https://github.com/zvx-echo6/central.git
synced 2026-05-22 10:34:43 +02:00
chore(lint-cleanup): remove 10 pre-existing ruff issues in 4 test files
Cleans up unused imports and dead locals flagged by ruff in the test files PR #50 (M-b) touched. Tests-only; no production code, no service restart. - test_supervisor_hotreload.py: drop unused AsyncMock/patch imports, dead expected_wait/expected_next_poll locals, and two dead state = AdapterState(...) blocks plus their now-orphaned local imports - test_supervisor_integration.py: drop unused asyncio/patch/pytest_asyncio imports and AdapterState from two function-local imports ruff tests/ 92 -> 82 (the 4 named files now 0; all other files unchanged). Full suite: 590 passed, 1 skipped (central and unprivileged zvx). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
e33a896592
commit
ff3d9bb3c3
2 changed files with 4 additions and 25 deletions
|
|
@ -9,15 +9,13 @@ IMPORTANT: These tests are designed to:
|
|||
- PASS on fixed code (last_completed_poll is preserved across disable/enable)
|
||||
"""
|
||||
|
||||
import asyncio
|
||||
import base64
|
||||
import os
|
||||
from datetime import datetime, timedelta, timezone
|
||||
from pathlib import Path
|
||||
from unittest.mock import AsyncMock, MagicMock, patch
|
||||
from unittest.mock import AsyncMock, MagicMock
|
||||
|
||||
import pytest
|
||||
import pytest_asyncio
|
||||
|
||||
from central.config_models import AdapterConfig
|
||||
from central.bootstrap_config import get_settings
|
||||
|
|
@ -195,7 +193,7 @@ class TestEnableDisableEnableIntegration:
|
|||
- Assert next poll fires immediately (last+cadence is in past)
|
||||
- Assert exactly ONE poll happens, not multiple catch-up
|
||||
"""
|
||||
from central.supervisor import Supervisor, AdapterState
|
||||
from central.supervisor import Supervisor
|
||||
|
||||
config_source = MockConfigSource()
|
||||
initial_config = AdapterConfig(
|
||||
|
|
@ -306,7 +304,7 @@ class TestEnableDisableEnableIntegration:
|
|||
- Re-enable adapter 20 seconds later (still within cadence window)
|
||||
- Assert next poll fires at last_poll + 60s, NOT immediately
|
||||
"""
|
||||
from central.supervisor import Supervisor, AdapterState
|
||||
from central.supervisor import Supervisor
|
||||
|
||||
config_source = MockConfigSource()
|
||||
initial_config = AdapterConfig(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue