Complete Phase 1: accumulator, exports, and full parity coverage

T05 — ride_accumulator.dart with the cross-batch anchor intact (12 tests).
T06 — ride_export.dart, GPX 1.1 and GeoJSON (15 tests), parsed with real
parsers rather than substring matching.
T07 — parity harness extended to cover export byte output.

GPX and GeoJSON are byte-identical across Kotlin and Dart: same length, same
FNV hash, including the escaped hostile name and all %.7f/%.1f formatting.

Two harness bugs found and fixed while building it. String.hashCode is not
comparable across Java and Dart, so text comparison used FNV-1a instead. And a
missing jar let a failed Kotlin compile pass as a green run -- run.sh now checks
for the artifact and exits non-zero, the same failure mode as the v2 sweep that
hid a compile error behind /dev/null.

Phase 1 done: 79 tests passing, analyze clean.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-15 01:08:30 -05:00
parent 4af4e3411a
commit 398157b1f5
12 changed files with 918 additions and 6 deletions

View File

@@ -8,3 +8,12 @@ data class TrackPoint(
data class Segment(
val id: Long = 0, val tripId: Long, val startedAt: Long, val endedAt: Long? = null,
) { val isOpen: Boolean get() = endedAt == null }
enum class TripState { RECORDING, PAUSED, COMPLETED }
data class Trip(
val id: Long = 0, val startedAt: Long, val endedAt: Long? = null,
val name: String? = null, val state: TripState = TripState.RECORDING,
val distanceM: Double = 0.0, val movingMillis: Long = 0,
val maxSpeedKmh: Float = 0f, val elevationGainM: Double = 0.0,
val pointCount: Int = 0,
)