1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
//! The harness's own [`Clock`] (DESIGN §7.2): a shared instant the test moves
//! by hand, so a beat about what yog does *over time* drives time instead of
//! racing the machine it runs on.
//!
//! **Why this exists** (bl-9006). `AppModel::boot` takes `Arc<dyn Clock>`
//! precisely so a test can supply one, and the crate's own unit suite already
//! does (`test_support::FakeClock`) — but that fake is `pub(crate)` and this is
//! a separate crate, so the seam was reachable and unused here. Every
//! integration beat therefore booted on `SystemClock` and measured **real**
//! elapsed time, which under a loaded gate is not the time the beat's author
//! ever saw: `stories_inv1` read a nine-tarpaulin machine as a yog that
//! mutated at idle, went red inside an unrelated agent's close, and read as
//! that agent's fault.
//!
//! The instant advances **only** when a test says so. That is the whole
//! contract, and it is what separates the two facts a real clock fuses: time
//! passing *between* passes (which is what makes §7.2's periodic sweeps fall
//! due, and is legitimate to simulate) from time passing *inside* one pass
//! (which is lateness, §7.2's `yog-drift late`, and belongs to the beat that
//! asserts lateness — `app::tests::worker`, on the crate's own lurching fake).
use ;
use ;
use Clock;
/// A clock frozen at construction, moved only by [`TestClock::advance`].
/// Handles share one instant, so the model's copy and the test's are the same
/// clock.