From d7e6eb7914d6246b0797ad915290fed7a40ecc84 Mon Sep 17 00:00:00 2001 From: Cian Johnston Date: Wed, 30 Apr 2025 09:18:58 +0100 Subject: [PATCH] chore(cli): fix test flake when running in coder workspace (#17604) This test was failing inside a Coder workspace due to `CODER_AGENT_TOKEN` being set. --- cli/exp_mcp_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/cli/exp_mcp_test.go b/cli/exp_mcp_test.go index 93c7acea74..c176546a8c 100644 --- a/cli/exp_mcp_test.go +++ b/cli/exp_mcp_test.go @@ -158,6 +158,7 @@ func TestExpMcpServer(t *testing.T) { //nolint:tparallel,paralleltest func TestExpMcpConfigureClaudeCode(t *testing.T) { t.Run("NoReportTaskWhenNoAgentToken", func(t *testing.T) { + t.Setenv("CODER_AGENT_TOKEN", "") ctx := testutil.Context(t, testutil.WaitShort) cancelCtx, cancel := context.WithCancel(ctx) t.Cleanup(cancel)