From 7bf2eb3d71d6671230c9438bf986a6a10ab21cbf Mon Sep 17 00:00:00 2001 From: Juan Font Alonso Date: Thu, 3 Nov 2022 17:00:23 +0100 Subject: [PATCH] Update Tailscale interface with new Execute signature --- integration/general_test.go | 10 +++++----- integration/tailscale.go | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/integration/general_test.go b/integration/general_test.go index 5edd0efc..a2982d16 100644 --- a/integration/general_test.go +++ b/integration/general_test.go @@ -168,7 +168,7 @@ func TestTaildrop(t *testing.T) { for _, client := range allClients { command := []string{"touch", fmt.Sprintf("/tmp/file_from_%s", client.Hostname())} - if _, err := client.Execute(command); err != nil { + if _, _, err := client.Execute(command); err != nil { t.Errorf("failed to create taildrop file on %s, err: %s", client.Hostname(), err) } @@ -193,7 +193,7 @@ func TestTaildrop(t *testing.T) { client.Hostname(), peer.Hostname(), ) - _, err := client.Execute(command) + _, _, err := client.Execute(command) return err }) @@ -214,7 +214,7 @@ func TestTaildrop(t *testing.T) { "get", "/tmp/", } - if _, err := client.Execute(command); err != nil { + if _, _, err := client.Execute(command); err != nil { t.Errorf("failed to get taildrop file on %s, err: %s", client.Hostname(), err) } @@ -234,7 +234,7 @@ func TestTaildrop(t *testing.T) { peer.Hostname(), ) - result, err := client.Execute(command) + result, _, err := client.Execute(command) if err != nil { t.Errorf("failed to execute command to ls taildrop: %s", err) } @@ -306,7 +306,7 @@ func TestResolveMagicDNS(t *testing.T) { "tailscale", "ip", peerFQDN, } - result, err := client.Execute(command) + result, _, err := client.Execute(command) if err != nil { t.Errorf( "failed to execute resolve/ip command %s from %s: %s", diff --git a/integration/tailscale.go b/integration/tailscale.go index aaf57aea..6e822fd7 100644 --- a/integration/tailscale.go +++ b/integration/tailscale.go @@ -10,7 +10,7 @@ type TailscaleClient interface { Hostname() string Shutdown() error Version() string - Execute(command []string) (string, error) + Execute(command []string) (string, string, error) Up(loginServer, authKey string) error IPs() ([]netip.Addr, error) FQDN() (string, error)