(t *testing.T)
| 294 | } |
| 295 | |
| 296 | func TestJSONRPCSuccess(t *testing.T) { |
| 297 | // 测试成功响应的创建 |
| 298 | result := map[string]string{"status": "ok"} |
| 299 | resp := NewSuccessResponse("req-1", result) |
| 300 | |
| 301 | assert.Equal(t, "2.0", resp.JSONRPC) |
| 302 | assert.Equal(t, "req-1", resp.ID) |
| 303 | assert.Nil(t, resp.Error) |
| 304 | assert.NotNil(t, resp.Result) |
| 305 | } |
nothing calls this directly
no test coverage detected