mirror of
https://github.com/juanfont/headscale.git
synced 2026-10-25 07:46:49 +09:00
state: compute primary routes inside NodeStore snapshot
Add primaries and isPrimary maps to Snapshot plus an election algorithm. No callers yet. Updates #3203
This commit is contained in:
1 parent
942313a10a
commit
da927eb018
2 files changed
+173
-9
No files matched your search
@@ -150,7 +150,7 @@ func TestSnapshotFromNodes(t *testing.T) {
|
||||
for _, tt := range tests {
|
||||
t.Run(tt.name, func(t *testing.T) {
|
||||
nodes, peersFunc := tt.setupFunc()
|
||||
snapshot := snapshotFromNodes(nodes, peersFunc)
|
||||
snapshot := snapshotFromNodes(nodes, peersFunc, nil)
|
||||
tt.validate(t, nodes, snapshot)
|
||||
})
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user