Change Peers to * Peers in identity to retrieve pointer to the real peer
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
@ -14,7 +14,7 @@ func TestGetFromPublicKey(t *testing.T) {
|
||||
var p Peer
|
||||
p.Name = "test" + strconv.Itoa(i)
|
||||
p.ContactPublicKey = "stringToFind" + strconv.Itoa(i)
|
||||
id.Peers = append(id.Peers, p)
|
||||
id.Peers = append(id.Peers, &p)
|
||||
}
|
||||
p5 := id.Peers.GetFromPublicKey("stringToFind5")
|
||||
assert.Equal(t, p5.Name, "test5")
|
||||
|
Reference in New Issue
Block a user