Versions in this module Expand all Collapse all v0 v0.2.1 Oct 17, 2025 Changes in this version type MockGiteaServer + func (m *MockGiteaServer) AddNotifications(notifications []MockNotification) + type MockNotification struct + ID int + Number int + Repository string + Title string + Type string + URL string + Unread bool + Updated string v0.2.0 Oct 17, 2025 Changes in this version type TestServer + func NewTestServerWithCompat(t *testing.T, ctx context.Context, env map[string]string, compat bool) *TestServer + func NewTestServerWithCompatAndDebug(t *testing.T, ctx context.Context, env map[string]string, debug, compat bool) *TestServer v0.1.2 Oct 16, 2025 v0.1.1 Oct 14, 2025 v0.1.0 Oct 7, 2025 Changes in this version + func AssertToolResultContains(t *testing.T, result *mcp.CallToolResult, expectedText string, ...) + func AssertToolResultEqual(t *testing.T, expected, actual *mcp.CallToolResult) + func CreateStandardTestContext(t *testing.T, timeoutSeconds int) (context.Context, context.CancelFunc) + func CreateTestContext(t *testing.T, timeout time.Duration) (context.Context, context.CancelFunc) + func GetStructuredContent(result *mcp.CallToolResult) map[string]any + func GetTextContent(content []mcp.Content) string + func RunConcurrentTest(t *testing.T, numGoroutines int, testFunc func(int) error) + func ValidateToolCall(t *testing.T, client *mcp.ClientSession, ctx context.Context, toolName string, ...) *mcp.CallToolResult + type MockComment struct + Author string + Content string + Created string + ID int + Updated string + type MockCommentUser struct + ID int + Username string + type MockGiteaServer struct + func NewMockGiteaServer(t *testing.T) *MockGiteaServer + func (m *MockGiteaServer) AddComments(owner, repo string, comments []MockComment) + func (m *MockGiteaServer) AddFile(owner, repo, ref, filepath string, content []byte) + func (m *MockGiteaServer) AddIssue(owner, repo string, issue MockIssue) + func (m *MockGiteaServer) AddIssues(owner, repo string, issues []MockIssue) + func (m *MockGiteaServer) AddPullRequests(owner, repo string, pullRequests []MockPullRequest) + func (m *MockGiteaServer) SetForbiddenCommentEdit(commentID int) + func (m *MockGiteaServer) SetNotFoundRepo(owner, repo string) + func (m *MockGiteaServer) SetServerErrorCommentEdit(commentID int) + func (m *MockGiteaServer) URL() string + type MockIssue struct + Body string + Created string + Index int + State string + Title string + Updated string + type MockPullRequest struct + BaseRef string + Body string + ID int + Number int + State string + Title string + UpdatedAt string + type TestServer struct + func NewTestServer(t *testing.T, ctx context.Context, env map[string]string) *TestServer + func NewTestServerWithDebug(t *testing.T, ctx context.Context, env map[string]string, debug bool) *TestServer + func (ts *TestServer) CallToolWithValidation(ctx context.Context, toolName string, arguments map[string]any) (*mcp.CallToolResult, error) + func (ts *TestServer) Client() *mcp.ClientSession + func (ts *TestServer) Initialize() error + func (ts *TestServer) IsRunning() bool + func (ts *TestServer) Start() error + func (ts *TestServer) ValidateErrorResult(result *mcp.CallToolResult, expectedErrorText string, t *testing.T) bool + func (ts *TestServer) ValidateSuccessResult(result *mcp.CallToolResult, expectedSuccessText string, t *testing.T) bool + func (ts *TestServer) ValidateToolResult(expected, actual *mcp.CallToolResult, t *testing.T) bool