File tree Expand file tree Collapse file tree 4 files changed +10
-7
lines changed Expand file tree Collapse file tree 4 files changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -187,7 +187,7 @@ func TestShellCallCommand(t *testing.T) {
187
187
name : "tool_name without params" ,
188
188
input : "test-tool\n /q\n " ,
189
189
expectedOutputs : []string {"Tool executed successfully" },
190
- expectedParams : map [string ]any {"name" : "test-tool" },
190
+ expectedParams : map [string ]any {"name" : "test-tool" , "arguments" : map [ string ] any {} },
191
191
mockResponses : map [string ]map [string ]any {
192
192
"tools/call" : {
193
193
"content" : []any {map [string ]any {"type" : "text" , "text" : "Tool executed successfully" }},
@@ -198,7 +198,7 @@ func TestShellCallCommand(t *testing.T) {
198
198
name : "call tool without params" ,
199
199
input : "call test-tool\n /q\n " ,
200
200
expectedOutputs : []string {"Tool executed successfully" },
201
- expectedParams : map [string ]any {"name" : "test-tool" },
201
+ expectedParams : map [string ]any {"name" : "test-tool" , "arguments" : map [ string ] any {} },
202
202
mockResponses : map [string ]map [string ]any {
203
203
"tools/call" : {
204
204
"content" : []any {map [string ]any {"type" : "text" , "text" : "Tool executed successfully" }},
Original file line number Diff line number Diff line change @@ -54,6 +54,11 @@ func (m *MockTransport) Close() error {
54
54
return nil
55
55
}
56
56
57
+ // GetSessionId is a no-op for the mock transport
58
+ func (m * MockTransport ) GetSessionId () string {
59
+ return ""
60
+ }
61
+
57
62
// setupMockClient creates a mock client with the given execute function and returns cleanup function.
58
63
func setupMockClient (executeFunc func (method string , _ any ) (map [string ]any , error )) func () {
59
64
// Save original function and restore later
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ module github.com/f/mcptools
3
3
go 1.24.1
4
4
5
5
require (
6
- github.com/mark3labs/mcp-go v0.24.1
6
+ github.com/mark3labs/mcp-go v0.34.0
7
7
github.com/peterh/liner v1.2.2
8
8
github.com/spf13/cobra v1.9.1
9
9
github.com/spf13/viper v1.20.1
Original file line number Diff line number Diff line change @@ -18,10 +18,8 @@ github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
18
18
github.com/kr/pretty v0.3.1 /go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk =
19
19
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY =
20
20
github.com/kr/text v0.2.0 /go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE =
21
- github.com/mark3labs/mcp-go v0.23.1 h1:RzTzZ5kJ+HxwnutKA4rll8N/pKV6Wh5dhCmiJUu5S9I =
22
- github.com/mark3labs/mcp-go v0.23.1 /go.mod h1:rXqOudj/djTORU/ThxYx8fqEVj/5pvTuuebQ2RC7uk4 =
23
- github.com/mark3labs/mcp-go v0.24.1 h1:YV+5X/+W4oBdERLWgiA1uR7AIvenlKJaa5V4hqufI7E =
24
- github.com/mark3labs/mcp-go v0.24.1 /go.mod h1:rXqOudj/djTORU/ThxYx8fqEVj/5pvTuuebQ2RC7uk4 =
21
+ github.com/mark3labs/mcp-go v0.34.0 h1:eWy7WBGvhk6EyAAyVzivTCprE52iXJwNtvHV6Cv3bR0 =
22
+ github.com/mark3labs/mcp-go v0.34.0 /go.mod h1:rXqOudj/djTORU/ThxYx8fqEVj/5pvTuuebQ2RC7uk4 =
25
23
github.com/mattn/go-runewidth v0.0.3 /go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU =
26
24
github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc =
27
25
github.com/mattn/go-runewidth v0.0.16 /go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w =
You can’t perform that action at this time.
0 commit comments