FakeSnapshotSource class

A fake SnapshotSource: a broadcast StreamController the test pushes through, plus a settable current (mirroring the real runtime's last-emitted accessor). push updates current AND emits, 1:1, like the change-gated runtime.

Implemented types

Constructors

FakeSnapshotSource([GraphSnapshot? _current])
Creates the fake source with an optional initial current.

Properties

current → GraphSnapshot?
The most recent snapshot, or null before the first baseline.
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
snapshots Stream<GraphSnapshot>
The work graph as it changes — change-gated, broadcast, non-replaying.
no setteroverride

Methods

close() Future<void>
Closes the stream (call from an addTearDown).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
push(GraphSnapshot snapshot) → void
Sets current and emits the snapshot to subscribers (after a microtask, like a real broadcast stream).
raiseError(Object error) → void
Emits an error on the stream WITHOUT touching current — a fake connection blip, so a consumer's absence-≠-deletion handling (tg-nsj D-Z3) can be proven without retracting the last known snapshot.
refreshQuietly(GraphSnapshot snapshot) → void
Sets current WITHOUT emitting — the change-gated runtime's QUIET refresh: a floor tick against an unchanged store advances current's capture time but publishes nothing (tg-zd4v freshness).
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited