mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
p2p/discover: ensure lookup in end-to-end test isn't self lookup
This commit is contained in:
parent
cb86630bed
commit
a8297b4a5a
1 changed files with 1 additions and 1 deletions
|
|
@ -51,7 +51,7 @@ func TestEndToEndV5(t *testing.T) {
|
|||
}
|
||||
|
||||
last := nodes[len(nodes)-1]
|
||||
target := nodes[rand.Intn(len(nodes))].Self()
|
||||
target := nodes[rand.Intn(len(nodes)-2)].Self()
|
||||
results := last.Lookup(target.ID())
|
||||
if len(results) == 0 || results[0].ID() != target.ID() {
|
||||
t.Fatalf("lookup returned wrong results: %v", results)
|
||||
|
|
|
|||
Loading…
Reference in a new issue