mirror of
https://github.com/netbirdio/netbird.git
synced 2026-10-03 20:19:07 +02:00
routeselector: remove duplicate IsDeselectAllActive
IsDeselectAllActive was identical to IsDeselectAll (both return the deselectAll flag under a read lock). The two were introduced in parallel on separate branches for the same fix - guarding against management route sync overriding a user's explicit deselect-all - and ended up coexisting after the branches merged. Drop IsDeselectAllActive, keep the canonical IsDeselectAll from main, and move its richer doc comment over. Update callers accordingly.
This commit is contained in:
@@ -116,7 +116,7 @@ func TestEnforceSingleExitNode_RespectsDeselectAll(t *testing.T) {
|
||||
|
||||
m.enforceSingleExitNode("b", []route.NetID{"a", "b"})
|
||||
|
||||
assert.True(t, m.routeSelector.IsDeselectAllActive(), "global deselect-all must stay in effect")
|
||||
assert.True(t, m.routeSelector.IsDeselectAll(), "global deselect-all must stay in effect")
|
||||
assert.False(t, m.routeSelector.IsSelected("b"), "no exit node should be forced on while deselect-all is set")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user