From c261fb198f1d3ee0c1bbe9db20ceef441f5be0e8 Mon Sep 17 00:00:00 2001 From: James Sanderson Date: Fri, 21 Mar 2025 12:00:01 +0000 Subject: [PATCH] tstest: make it clearer where AwaitRunning failed and why Signed-off-by: James Sanderson --- tstest/integration/integration_test.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tstest/integration/integration_test.go b/tstest/integration/integration_test.go index 770abd506..81a1cd9dc 100644 --- a/tstest/integration/integration_test.go +++ b/tstest/integration/integration_test.go @@ -1942,6 +1942,8 @@ func (n *testNode) AwaitIP6() netip.Addr { // AwaitRunning waits for n to reach the IPN state "Running". func (n *testNode) AwaitRunning() { + t := n.env.t + t.Helper() n.AwaitBackendState("Running") } @@ -2015,7 +2017,7 @@ func (n *testNode) Status() (*ipnstate.Status, error) { } st := new(ipnstate.Status) if err := json.Unmarshal(out, st); err != nil { - return nil, fmt.Errorf("decoding tailscale status JSON: %w", err) + return nil, fmt.Errorf("decoding tailscale status JSON: %w\njson:\n%s", err, out) } return st, nil }