mirror of
https://github.com/ipfs/kubo.git
synced 2025-06-30 18:13:54 +08:00
mark other nodes in routing table on test-connect
License: MIT Signed-off-by: Jeromy <jeromyj@gmail.com>
This commit is contained in:
@ -78,6 +78,14 @@ func connect(t *testing.T, ctx context.Context, a, b *IpfsDHT) {
|
|||||||
if err := a.host.Connect(ctx, pi); err != nil {
|
if err := a.host.Connect(ctx, pi); err != nil {
|
||||||
t.Fatal(err)
|
t.Fatal(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for a.routingTable.Find(b.self) == "" {
|
||||||
|
time.Sleep(time.Millisecond * 5)
|
||||||
|
}
|
||||||
|
|
||||||
|
for b.routingTable.Find(a.self) == "" {
|
||||||
|
time.Sleep(time.Millisecond * 5)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func bootstrap(t *testing.T, ctx context.Context, dhts []*IpfsDHT) {
|
func bootstrap(t *testing.T, ctx context.Context, dhts []*IpfsDHT) {
|
||||||
|
Reference in New Issue
Block a user