mirror of
https://github.com/azaion/gps-denied-onboard.git
synced 2026-06-22 21:31:13 +00:00
feat(02-04): decorate 7 test files with @pytest.mark.ac markers
- test_acceptance.py: 8 decorators (AC-1.1, AC-2.1a, AC-3.3, AC-3.4, AC-4.1, AC-4.4, AC-1.4) - test_accuracy.py: 11 decorators (AC-1.1, AC-1.2, AC-1.3, AC-2.1a, AC-2.2, AC-4.1) - test_processor_pipe.py: 2 decorators (AC-4.4, AC-1.4) - test_gps_input_encoding.py: module-level pytestmark for AC-4.3 (13 tests) - test_sitl_integration.py: 9 decorators (AC-4.3, AC-4.4, AC-NEW-2, AC-5.2, AC-3.4) - test_mavlink.py: 5 decorators (AC-4.3, AC-5.2, AC-3.4) - test_schemas.py: 2 class-level decorators (AC-6.3, AC-6.3) - 14 non-deferred ACs covered; 45 tests collected under -m ac
This commit is contained in:
@@ -61,6 +61,8 @@ def _random_frame(h=200, w=200):
|
||||
# ---------------------------------------------------------------
|
||||
# AC-1: Normal flight — 20 consecutive frames
|
||||
# ---------------------------------------------------------------
|
||||
@pytest.mark.ac("AC-1.1")
|
||||
@pytest.mark.ac("AC-4.4")
|
||||
@pytest.mark.asyncio
|
||||
async def test_ac1_normal_flight(wired_processor):
|
||||
"""Twenty frames processed without crash; SSE events emitted for each."""
|
||||
@@ -76,6 +78,8 @@ async def test_ac1_normal_flight(wired_processor):
|
||||
# ---------------------------------------------------------------
|
||||
# AC-2: Tracking loss → recovery cycle
|
||||
# ---------------------------------------------------------------
|
||||
@pytest.mark.ac("AC-2.1a")
|
||||
@pytest.mark.ac("AC-3.4")
|
||||
@pytest.mark.asyncio
|
||||
async def test_ac2_tracking_loss_and_recovery(wired_processor, monkeypatch):
|
||||
"""
|
||||
@@ -122,6 +126,7 @@ async def test_ac2_tracking_loss_and_recovery(wired_processor, monkeypatch):
|
||||
# ---------------------------------------------------------------
|
||||
# AC-3: Performance — < 5 s per frame
|
||||
# ---------------------------------------------------------------
|
||||
@pytest.mark.ac("AC-4.1")
|
||||
@pytest.mark.asyncio
|
||||
async def test_ac3_performance_per_frame(wired_processor):
|
||||
"""Each process_frame call must complete in < 5 seconds (mock pipeline)."""
|
||||
@@ -144,6 +149,8 @@ async def test_ac3_performance_per_frame(wired_processor):
|
||||
# ---------------------------------------------------------------
|
||||
# AC-4: User anchor fix
|
||||
# ---------------------------------------------------------------
|
||||
@pytest.mark.ac("AC-4.4")
|
||||
@pytest.mark.ac("AC-1.4")
|
||||
@pytest.mark.asyncio
|
||||
async def test_ac4_user_anchor_fix(wired_processor):
|
||||
"""
|
||||
@@ -185,6 +192,8 @@ async def test_ac4_user_anchor_fix(wired_processor):
|
||||
# ---------------------------------------------------------------
|
||||
# AC-5: Sustained throughput — 50 frames
|
||||
# ---------------------------------------------------------------
|
||||
@pytest.mark.ac("AC-1.1")
|
||||
@pytest.mark.ac("AC-4.4")
|
||||
@pytest.mark.asyncio
|
||||
async def test_ac5_sustained_throughput(wired_processor):
|
||||
"""Process 50 frames back-to-back; no crashes, total < 30 seconds."""
|
||||
@@ -201,6 +210,7 @@ async def test_ac5_sustained_throughput(wired_processor):
|
||||
# ---------------------------------------------------------------
|
||||
# AC-6: Factor graph optimization converges
|
||||
# ---------------------------------------------------------------
|
||||
@pytest.mark.ac("AC-3.3")
|
||||
@pytest.mark.asyncio
|
||||
async def test_ac6_graph_optimization_convergence(wired_processor):
|
||||
"""After N frames the graph should report convergence."""
|
||||
|
||||
Reference in New Issue
Block a user