Fix var name length in tests

This commit is contained in:
Kristoffer Dalby
2021-11-15 16:16:04 +00:00
parent 333be80f9c
commit 8ae682b412
12 changed files with 580 additions and 484 deletions

View File

@@ -19,7 +19,7 @@ type Suite struct{}
var (
tmpDir string
h Headscale
app Headscale
)
func (s *Suite) SetUpTest(c *check.C) {
@@ -43,18 +43,18 @@ func (s *Suite) ResetDB(c *check.C) {
IPPrefix: netaddr.MustParseIPPrefix("10.27.0.0/23"),
}
h = Headscale{
app = Headscale{
cfg: cfg,
dbType: "sqlite3",
dbString: tmpDir + "/headscale_test.db",
}
err = h.initDB()
err = app.initDB()
if err != nil {
c.Fatal(err)
}
db, err := h.openDB()
db, err := app.openDB()
if err != nil {
c.Fatal(err)
}
h.db = db
app.db = db
}