tstest/integration: add experimental integration test (#1966)

This will spin up a few vms and then try and make them connect to a
testcontrol server.

Updates #1988

Signed-off-by: Christine Dodrill <xe@tailscale.com>
This commit is contained in:
Christine Dodrill
2021-05-26 14:10:10 -04:00
committed by GitHub
parent 60e920bf18
commit ba59c0391b
5 changed files with 556 additions and 0 deletions

View File

@@ -56,6 +56,17 @@ type Server struct {
nodeKeyAuthed map[tailcfg.NodeKey]bool // key => true once authenticated
}
// NumNodes returns the number of nodes in the testcontrol server.
//
// This is useful when connecting a bunch of virtual machines to a testcontrol
// server to see how many of them connected successfully.
func (s *Server) NumNodes() int {
s.mu.Lock()
defer s.mu.Unlock()
return len(s.nodes)
}
type AuthPath struct {
nodeKey tailcfg.NodeKey