@@ -136,15 +136,15 @@ func TestClient_LivenessManager_HandleRx_Transitions_AddAndDelete(t *testing.T)
136136 }()
137137 require .NotNil (t , sess )
138138
139- m .HandleRx (& ControlPacket {peerDiscrr : 0 , LocalDiscrr : 1234 , State : StateDown }, peer )
139+ m .HandleRx (& ControlPacket {PeerDiscr : 0 , LocalDiscr : 1234 , State : StateDown }, peer )
140140 func () {
141141 sess .mu .Lock ()
142142 defer sess .mu .Unlock ()
143143 require .Equal (t , StateInit , sess .state )
144144 require .EqualValues (t , 1234 , sess .peerDiscr )
145145 }()
146146
147- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateInit }, peer )
147+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateInit }, peer )
148148 added := wait (t , addCh , 2 * time .Second , "RouteAdd after Up" )
149149 require .Equal (t , r .Table , added .Table )
150150 require .Equal (t , r .Src .String (), added .Src .String ())
@@ -158,7 +158,7 @@ func TestClient_LivenessManager_HandleRx_Transitions_AddAndDelete(t *testing.T)
158158 require .Equal (t , StateUp , sess .state )
159159 m .mu .Unlock ()
160160
161- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateDown }, peer )
161+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateDown }, peer )
162162 deleted := wait (t , delCh , 2 * time .Second , "RouteDelete after Down" )
163163 require .Equal (t , r .Table , deleted .Table )
164164 require .Equal (t , r .Src .String (), deleted .Src .String ())
@@ -207,9 +207,9 @@ func TestClient_LivenessManager_WithdrawRoute_RemovesSessionAndDeletesIfInstalle
207207 }
208208 }()
209209 // Down -> Init (learn peerDiscr)
210- m .HandleRx (& ControlPacket {peerDiscrr : 0 , LocalDiscrr : 1 , State : StateInit }, peer )
211- // Init -> Up requires explicit echo (peerDiscrr == localDiscr)
212- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateInit }, peer )
210+ m .HandleRx (& ControlPacket {PeerDiscr : 0 , LocalDiscr : 1 , State : StateInit }, peer )
211+ // Init -> Up requires explicit echo (PeerDiscr == localDiscr)
212+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateInit }, peer )
213213 wait (t , addCh , 2 * time .Second , "RouteAdd before withdraw" )
214214
215215 require .NoError (t , m .WithdrawRoute (r , "lo" ))
@@ -265,7 +265,7 @@ func TestClient_LivenessManager_HandleRx_UnknownPeer_NoEffect(t *testing.T) {
265265
266266 // Construct a peer key that doesn't exist.
267267 unknown := Peer {Interface : "lo" , LocalIP : "127.0.0.2" , PeerIP : "127.0.0.3" }
268- m .HandleRx (& ControlPacket {peerDiscrr : 0 , LocalDiscrr : 1 , State : StateInit }, unknown )
268+ m .HandleRx (& ControlPacket {PeerDiscr : 0 , LocalDiscr : 1 , State : StateInit }, unknown )
269269
270270 // Assert no changes.
271271 m .mu .Lock ()
@@ -312,8 +312,8 @@ func TestClient_LivenessManager_NetlinkerErrors_NoCrash(t *testing.T) {
312312 require .NotNil (t , sess )
313313
314314 // Drive to Up (RouteAdd returns error but should not crash; installed set true).
315- m .HandleRx (& ControlPacket {peerDiscrr : 0 , LocalDiscrr : 99 , State : StateDown }, peer ) // Down -> Init
316- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateUp }, peer ) // Init -> Up
315+ m .HandleRx (& ControlPacket {PeerDiscr : 0 , LocalDiscr : 99 , State : StateDown }, peer ) // Down -> Init
316+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateUp }, peer ) // Init -> Up
317317
318318 rk := routeKeyFor (peer .Interface , sess .route )
319319 time .Sleep (50 * time .Millisecond ) // allow onSessionUp goroutine to run
@@ -323,7 +323,7 @@ func TestClient_LivenessManager_NetlinkerErrors_NoCrash(t *testing.T) {
323323 m .mu .Unlock ()
324324
325325 // Drive to Down (RouteDelete returns error; should not crash; installed set false).
326- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateDown }, peer )
326+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateDown }, peer )
327327 time .Sleep (50 * time .Millisecond )
328328
329329 m .mu .Lock ()
@@ -363,9 +363,9 @@ func TestClient_LivenessManager_PassiveMode_ImmediateInstall_NoAutoWithdraw(t *t
363363 break
364364 }
365365 }()
366- m .HandleRx (& ControlPacket {peerDiscrr : 0 , LocalDiscrr : 1 , State : StateInit }, peer )
367- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateUp }, peer )
368- m .HandleRx (& ControlPacket {peerDiscrr : sess .localDiscr , LocalDiscrr : sess .peerDiscr , State : StateDown }, peer )
366+ m .HandleRx (& ControlPacket {PeerDiscr : 0 , LocalDiscr : 1 , State : StateInit }, peer )
367+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateUp }, peer )
368+ m .HandleRx (& ControlPacket {PeerDiscr : sess .localDiscr , LocalDiscr : sess .peerDiscr , State : StateDown }, peer )
369369
370370 select {
371371 case <- delCh :
0 commit comments