mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-29 14:00:31 +08:00
node: improve seeds information
Previously, the seeds information would only consist of the connected NodeIds. Improve on this by adding any disconnected and fetching seeds as well. A seed can either be disconnected, connected, or fetching -- where fetching implies connected. Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com> X-Clacks-Overhead: GNU Terry Pratchett
This commit is contained in:
@@ -159,7 +159,7 @@ fn test_replication() {
|
||||
assert!(tracked);
|
||||
|
||||
let seeds = alice.handle.seeds(acme).unwrap();
|
||||
assert!(seeds.contains(&bob.id));
|
||||
assert!(seeds.is_connected(&bob.id));
|
||||
|
||||
let result = alice.handle.fetch(acme, bob.id).unwrap();
|
||||
assert!(result.is_success());
|
||||
@@ -213,7 +213,7 @@ fn test_clone() {
|
||||
|
||||
let _ = alice.handle.track_repo(acme).unwrap();
|
||||
let seeds = alice.handle.seeds(acme).unwrap();
|
||||
assert!(seeds.contains(&bob.id));
|
||||
assert!(seeds.is_connected(&bob.id));
|
||||
|
||||
let result = alice.handle.fetch(acme, bob.id).unwrap();
|
||||
assert!(result.is_success());
|
||||
|
||||
Reference in New Issue
Block a user