MCPcopy Create free account
hub / github.com/ajitpratap0/GoSQLX / TestServer_AuthDisabled

Function TestServer_AuthDisabled

pkg/mcp/server_test.go:40–49  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

38}
39
40func TestServer_AuthDisabled(t *testing.T) {
41 cfg := DefaultConfig()
42 if cfg.AuthEnabled() {
43 t.Error("DefaultConfig should have auth disabled")
44 }
45 srv := New(cfg)
46 if srv == nil {
47 t.Fatal("New() returned nil")
48 }
49}
50
51func TestServer_AuthEnabled(t *testing.T) {
52 cfg := &Config{Host: "127.0.0.1", Port: 8080, AuthToken: "testtoken"}

Callers

nothing calls this directly

Calls 4

AuthEnabledMethod · 0.80
DefaultConfigFunction · 0.70
NewFunction · 0.70
ErrorMethod · 0.45

Tested by

no test coverage detected