diff options
| author | tv <tv@krebsco.de> | 2026-11-16 18:11:25 +0000 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-11-16 19:18:22 +0100 |
| commit | 0b011438496d3f9245033d1ebb58a4cbebd88f00 (patch) | |
| tree | c923149e7075430a274db2039d00fdfd403942e0 /src/federation/mod.rs | |
| parent | 0231b7732b8c005e956a5b112c0e4fdddc38429e (diff) | |
federation: a test for each attack marked unit
Each row of `docs/federation.md`'s attacks marked unit that the fold and the store in
memory answer has its test, named by its row (`federation_attack_12`), with events made
for it by the harness: keys that aren't their party's, bytes that are none, events of
another federation or a fork, writes where a party held or holds no place, key sets
and keys stolen or dropped, votes cast twice, at once, split, or at a history from
before, versions that are none or written again late, two versions changing one in
every order, forks and roots, checkpoints, events not above their heads, and heads a
version may not name.
`every_row_marked_unit_has_its_test` reads the table and this file, and checks that
every row marked unit has its test, or waits for a later stage (what a node, a party's
client or a tool does, and what a node tells of a fork), and that no test names a row
that isn't there.
Diffstat (limited to 'src/federation/mod.rs')
| -rw-r--r-- | src/federation/mod.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/federation/mod.rs b/src/federation/mod.rs index 2be6632..bbafbc7 100644 --- a/src/federation/mod.rs +++ b/src/federation/mod.rs @@ -5,6 +5,8 @@ // Until a node runs it (stage 3), parts of it are used by nothing, or by tests alone. #![allow(dead_code)] +#[cfg(test)] +mod attacks; pub(crate) mod event; pub(crate) mod fold; #[cfg(test)] |
