Coverage Summary for Class: PendingMutation (com.georgeci.moneysurfer.sync.repository)

Class Class, % Method, % Branch, % Line, % Instruction, %
PendingMutation 100% (1/1) 100% (1/1) 100% (9/9) 100% (42/42)


 package com.georgeci.moneysurfer.sync.repository
 
 import kotlin.time.Instant
 
 /**
  * One queued local mutation awaiting push to the remote backend.
  *
  * Outbox row identity is [id] (UUID), independent from the entity's own id โ€”
  * the same entity may have multiple sequential mutations.
  *
  * [entityType] is an opaque string (e.g. "ACCOUNT", "TRANSACTION") defined as
  * constants in [com.georgeci.moneysurfer.domain.sync.SyncEntityTypes].
  * [scopeKey] carries the workspace id for subcollection entities, or null for
  * root-collection entities (e.g. workspace itself, users).
  *
  * The push worker reads the entity from Room at push time โ€” no payload is stored
  * in the outbox. See sync.md ยง4.3 and SyncCoordinatorFAQ.md โ„–13.
  */
 data class PendingMutation(
     val id: String,
     val entityType: String,
     val entityId: String,
     val operation: MutationOperation,
     val scopeKey: String?,
     val createdAt: Instant,
     val attempts: Int,
     val lastError: String?,
 )