mirror of
https://github.com/juanfont/headscale.git
synced 2024-11-26 08:53:05 +00:00
tests: fix TestDERPVerifyEndpoint
This commit is contained in:
parent
dfebd176df
commit
b39925f576
2 changed files with 4 additions and 3 deletions
|
@ -33,10 +33,10 @@ func TestDERPVerifyEndpoint(t *testing.T) {
|
|||
|
||||
scenario, err := NewScenario(dockertestMaxWait())
|
||||
assertNoErr(t, err)
|
||||
defer scenario.Shutdown()
|
||||
defer scenario.ShutdownAssertNoPanics(t)
|
||||
|
||||
spec := map[string]int{
|
||||
"user1": 10,
|
||||
"user1": len(MustTestVersions),
|
||||
}
|
||||
|
||||
derper, err := scenario.CreateDERPServer("head",
|
||||
|
|
|
@ -25,6 +25,7 @@ import (
|
|||
"github.com/juanfont/headscale/integration/integrationutil"
|
||||
"github.com/ory/dockertest/v3"
|
||||
"github.com/ory/dockertest/v3/docker"
|
||||
"gopkg.in/yaml.v3"
|
||||
"tailscale.com/tailcfg"
|
||||
)
|
||||
|
||||
|
@ -221,7 +222,7 @@ func WithEmbeddedDERPServerOnly() Option {
|
|||
// DERP server only.
|
||||
func WithDERPConfig(derpMap tailcfg.DERPMap) Option {
|
||||
return func(hsic *HeadscaleInContainer) {
|
||||
contents, err := json.Marshal(derpMap)
|
||||
contents, err := yaml.Marshal(derpMap)
|
||||
if err != nil {
|
||||
log.Fatalf("failed to marshal DERP map: %s", err)
|
||||
|
||||
|
|
Loading…
Reference in a new issue