Audit fixes.
This commit is contained in:
@@ -268,7 +268,7 @@ func TestSwitchActiveRelay(t *testing.T) {
|
|||||||
name: "stale relay demoted to direct before backup elected",
|
name: "stale relay demoted to direct before backup elected",
|
||||||
setup: func(t *testing.T, a *App) {
|
setup: func(t *testing.T, a *App) {
|
||||||
old := addRelayPeer(t, a, "10.0.0.10", ep1)
|
old := addRelayPeer(t, a, "10.0.0.10", ep1)
|
||||||
old.wgPeer.LastHandshakeTime = time.Time{} // stale — triggers switch from onTick
|
old.LastPing = time.Time{} // stale — Up() checks LastPing; triggers switch — triggers switch from onTick
|
||||||
a.relay = old
|
a.relay = old
|
||||||
addRelayPeer(t, a, "10.0.0.11", ep2)
|
addRelayPeer(t, a, "10.0.0.11", ep2)
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user