make reauth test compat with tailscale head (#2167)
* make reauth test compat with tailscale head tailscale/tailscale@1eaad7d broke our reauth test as it makes the client retry with https/443 if it reconnects within 2 minutes. This commit fixes this by running the test as a two part, - with https, to confirm instant reconnect works - with http, and a 3 min wait, to check that it work without. The change is not a general consern as headscale in prod is ran with https. Updates #2164 Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com> * sort test for stable order Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com> --------- Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com>
This commit is contained in:
parent
e16ea2ee69
commit
9515040161
2 changed files with 125 additions and 99 deletions
|
@ -1,6 +1,7 @@
|
|||
package db
|
||||
|
||||
import (
|
||||
"sort"
|
||||
"time"
|
||||
|
||||
"github.com/juanfont/headscale/hscontrol/types"
|
||||
|
@ -169,5 +170,7 @@ func (*Suite) TestPreAuthKeyACLTags(c *check.C) {
|
|||
|
||||
listedPaks, err := db.ListPreAuthKeys("test8")
|
||||
c.Assert(err, check.IsNil)
|
||||
c.Assert(listedPaks[0].Proto().GetAclTags(), check.DeepEquals, tags)
|
||||
gotTags := listedPaks[0].Proto().GetAclTags()
|
||||
sort.Sort(sort.StringSlice(gotTags))
|
||||
c.Assert(gotTags, check.DeepEquals, tags)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue