Skip to content

[LOW] ViewModel test harness for rider and driver flows #43

@variablefate

Description

@variablefate

Description

Add comprehensive ViewModel-level tests for RiderViewModel and DriverViewModel to cover ride flow state transitions, subscription lifecycle, and edge cases.

Context

The common module already has a test infrastructure (FakeMintApi, FakeNip60Store, MainDispatcherRule) and payment/proof-conservation tests. This would extend test coverage to the ViewModel layer.

Scope

  • RiderViewModel: offer flows (direct, broadcast, RoadFlare, batch), state transitions, cancellation paths, EOSE reconciliation
  • DriverViewModel: availability lifecycle, offer acceptance, ride state broadcasting, RoadFlare mode transitions
  • Mock NostrService interactions
  • Verify subscription cleanup on ride-ending paths
  • Verify race guard behavior (confirmationInFlight, hasAcceptedDriver)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions