(t *testing.T, a, b host.Host, as, bs map[common.Address][]uint64)
| 320 | } |
| 321 | |
| 322 | func connect(t *testing.T, a, b host.Host, as, bs map[common.Address][]uint64) { |
| 323 | pinfo := a.Peerstore().PeerInfo(a.ID()) |
| 324 | a.Peerstore().Put(b.ID(), EthStorageENRKey, ConvertToContractShards(bs)) |
| 325 | b.Peerstore().Put(a.ID(), EthStorageENRKey, ConvertToContractShards(as)) |
| 326 | err := b.Connect(context.Background(), pinfo) |
| 327 | if err != nil { |
| 328 | t.Fatal(err) |
| 329 | } |
| 330 | } |
| 331 | |
| 332 | func createLocalHostAndSyncClient(t *testing.T, chainID *big.Int, db ethdb.Database, |
| 333 | storageManager StorageManager, metrics SyncClientMetrics, mux *event.Feed) (host.Host, *SyncClient) { |
no test coverage detected