Summary
GeoUtils.kt contains pure functions distanceMiles() (Haversine formula) and fuelLabel() (fuel code mapping) with no test coverage.
What to test
File: backend/src/main/kotlin/uk/co/fueller/backend/GeoUtils.kt
| Test |
Description |
distanceMiles_zeroForSamePoint |
Same lat/lon → 0.0 miles |
distanceMiles_londonToManchester |
Known distance within ~1% tolerance |
distanceMiles_antipodal |
~12,450 miles for opposite points |
fuelLabel_E10 |
Returns "Unleaded" or expected label |
fuelLabel_B7 |
Returns "Diesel" |
fuelLabel_unknown |
Returns raw code or graceful fallback |
Workstream: WS2 Phase 2A
Summary
GeoUtils.ktcontains pure functionsdistanceMiles()(Haversine formula) andfuelLabel()(fuel code mapping) with no test coverage.What to test
File:
backend/src/main/kotlin/uk/co/fueller/backend/GeoUtils.ktdistanceMiles_zeroForSamePointdistanceMiles_londonToManchesterdistanceMiles_antipodalfuelLabel_E10fuelLabel_B7fuelLabel_unknownWorkstream: WS2 Phase 2A