lib

Core libraries for Radroots
git clone https://radroots.dev/git/lib.git
Log | Files | Refs | README | LICENSE

commit 5afe5c0456f23145877956e56b0d242df223d059
parent acde2b7d842ec7cb7a550fdfecce4943cca960c0
Author: triesap <tyson@radroots.org>
Date:   Fri,  6 Mar 2026 17:33:40 +0000

replica-sync: normalize rustfmt layout in remaining tests

- apply rustfmt wrapping updates in canonical serialization assertions
- apply rustfmt wrapping updates in emit and sync-state test helpers
- apply rustfmt wrapping updates in ingest_roundtrip test setup
- keep replica-sync behavior unchanged while isolating formatting-only deltas

Diffstat:
Mcrates/replica-sync/src/canonical.rs | 5++++-
Mcrates/replica-sync/src/emit.rs | 4++--
Mcrates/replica-sync/src/sync_state.rs | 4++--
Mcrates/replica-sync/tests/ingest_roundtrip.rs | 7+++++--
4 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/crates/replica-sync/src/canonical.rs b/crates/replica-sync/src/canonical.rs @@ -106,7 +106,10 @@ mod tests { fn canonical_json_string_failpoint_returns_error() { super::failpoints::set_error(); let err = canonical_json_string(&"value").expect_err("failpoint"); - assert!(err.to_string().contains("canonical json serialization failed")); + assert!( + err.to_string() + .contains("canonical json serialization failed") + ); } struct AlwaysErr; diff --git a/crates/replica-sync/src/emit.rs b/crates/replica-sync/src/emit.rs @@ -1531,8 +1531,8 @@ mod tests { let plot_events = radroots_replica_plot_events(&exec, &farm).expect("plot events"); assert_eq!(plot_events.len(), 1); - let claims = radroots_replica_membership_claim_events(&exec, &"z".repeat(64)) - .expect("empty claims"); + let claims = + radroots_replica_membership_claim_events(&exec, &"z".repeat(64)).expect("empty claims"); assert!(claims.is_empty()); let by_pair = resolve_farm( diff --git a/crates/replica-sync/src/sync_state.rs b/crates/replica-sync/src/sync_state.rs @@ -117,8 +117,8 @@ mod tests { d_tag: None, pubkey: None, }; - let bundle = radroots_replica_sync_all_with_options(&exec, &selector, None) - .expect("bundle"); + let bundle = + radroots_replica_sync_all_with_options(&exec, &selector, None).expect("bundle"); let expected_count = bundle.events.len(); let first = bundle.events.first().expect("event"); let d_tag = tag_value(&first.tags, "d").unwrap_or(""); diff --git a/crates/replica-sync/tests/ingest_roundtrip.rs b/crates/replica-sync/tests/ingest_roundtrip.rs @@ -165,8 +165,11 @@ fn seed_source( gc_country_id: None, gc_country_name: None, }; - let gcs_secondary_row = - unwrap_sql(gcs_location::create(exec, &gcs_secondary_fields), "gcs secondary").result; + let gcs_secondary_row = unwrap_sql( + gcs_location::create(exec, &gcs_secondary_fields), + "gcs secondary", + ) + .result; let _ = unwrap_sql( farm_gcs_location::create(