Skip to content

Commit 6c51c9d

Browse files
committed
test(profiles): test default profile is full
1 parent d26f896 commit 6c51c9d

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

pkg/kubernetes-mcp-server/cmd/root_test.go

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ package cmd
33
import (
44
"io"
55
"os"
6+
"strings"
67
"testing"
78
)
89

@@ -24,6 +25,13 @@ func TestVersion(t *testing.T) {
2425
version, err := captureOutput(rootCmd.Execute)
2526
if version != "0.0.0\n" {
2627
t.Fatalf("Expected version 0.0.0, got %s %v", version, err)
27-
return
28+
}
29+
}
30+
31+
func TestDefaultProfile(t *testing.T) {
32+
rootCmd.SetArgs([]string{"--version", "--log-level=1"})
33+
out, err := captureOutput(rootCmd.Execute)
34+
if !strings.Contains(out, "Starting kubernetes-mcp-server with profile: full") {
35+
t.Fatalf("Expected profile 'full', got %s %v", out, err)
2836
}
2937
}

0 commit comments

Comments
 (0)