QA: add structural and model tests for story 1.1 scaffold
Replaces placeholder stubs in test_models.py, test_gpio_ctrl.py, and provisioning/test_provision_loop.py with real assertions. Adds new test_scaffold.py covering AC3 file-presence, importlib.resources airports.csv load, constants completeness, and main.py provisioning import guard. Extends ruff per-file-ignores so tests/provisioning/*.py may import from planemapper.provisioning. All 22 tests pass; ruff check and format --check both clean. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+28
-2
@@ -1,2 +1,28 @@
|
||||
def test_placeholder() -> None:
|
||||
pass
|
||||
from planemapper.models import Aircraft
|
||||
|
||||
|
||||
def test_aircraft_defaults() -> None:
|
||||
a = Aircraft(icao="ABC123", lat=51.5, lon=-0.1)
|
||||
assert a.heading == 0.0
|
||||
assert a.altitude_ft == 0
|
||||
assert a.callsign == ""
|
||||
assert a.category == ""
|
||||
assert a.is_mlat is False
|
||||
assert a.is_stale is False
|
||||
|
||||
|
||||
def test_aircraft_full() -> None:
|
||||
a = Aircraft(
|
||||
icao="ABC123",
|
||||
lat=51.5,
|
||||
lon=-0.1,
|
||||
heading=90.0,
|
||||
altitude_ft=5000,
|
||||
callsign="BAW1",
|
||||
category="A3",
|
||||
is_mlat=True,
|
||||
is_stale=False,
|
||||
)
|
||||
assert a.heading == 90.0
|
||||
assert a.callsign == "BAW1"
|
||||
assert a.is_mlat is True
|
||||
|
||||
Reference in New Issue
Block a user