mirror of
https://github.com/tailscale/tailscale.git
synced 2025-08-11 21:27:31 +00:00
all: use tstest.Replace more
Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
@@ -14,6 +14,7 @@ import (
|
||||
"tailscale.com/client/tailscale/apitype"
|
||||
"tailscale.com/hostinfo"
|
||||
"tailscale.com/ipn/ipnlocal"
|
||||
"tailscale.com/tstest"
|
||||
)
|
||||
|
||||
func TestValidHost(t *testing.T) {
|
||||
@@ -42,10 +43,7 @@ func TestValidHost(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestSetPushDeviceToken(t *testing.T) {
|
||||
validLocalHostForTesting = true
|
||||
defer func() {
|
||||
validLocalHostForTesting = false
|
||||
}()
|
||||
tstest.Replace(t, &validLocalHostForTesting, true)
|
||||
|
||||
h := &Handler{
|
||||
PermitWrite: true,
|
||||
|
Reference in New Issue
Block a user