MCPcopy Index your code
hub / github.com/github/github-mcp-server / TestGranularToolSnaps

Function TestGranularToolSnaps

pkg/github/granular_tools_test.go:32–69  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

30}
31
32func TestGranularToolSnaps(t *testing.T) {
33 // Test toolsnaps for all granular tools
34 toolConstructors := []func(translations.TranslationHelperFunc) inventory.ServerTool{
35 GranularCreateIssue,
36 GranularUpdateIssueTitle,
37 GranularUpdateIssueBody,
38 GranularUpdateIssueAssignees,
39 GranularUpdateIssueLabels,
40 GranularUpdateIssueMilestone,
41 GranularUpdateIssueType,
42 GranularUpdateIssueState,
43 GranularAddSubIssue,
44 GranularRemoveSubIssue,
45 GranularReprioritizeSubIssue,
46 GranularSetIssueFields,
47 GranularAddIssueReaction,
48 GranularAddIssueCommentReaction,
49 GranularUpdatePullRequestTitle,
50 GranularUpdatePullRequestBody,
51 GranularUpdatePullRequestState,
52 GranularUpdatePullRequestDraftState,
53 GranularRequestPullRequestReviewers,
54 GranularCreatePullRequestReview,
55 GranularSubmitPendingPullRequestReview,
56 GranularDeletePendingPullRequestReview,
57 GranularAddPullRequestReviewComment,
58 GranularResolveReviewThread,
59 GranularUnresolveReviewThread,
60 GranularAddPullRequestReviewCommentReaction,
61 }
62
63 for _, constructor := range toolConstructors {
64 serverTool := constructor(translations.NullTranslationHelper)
65 t.Run(serverTool.Tool.Name, func(t *testing.T) {
66 require.NoError(t, toolsnaps.Test(serverTool.Tool.Name, serverTool.Tool))
67 })
68 }
69}
70
71func TestIssuesGranularToolset(t *testing.T) {
72 t.Run("toolset contains expected granular tools", func(t *testing.T) {

Callers

nothing calls this directly

Calls 1

TestFunction · 0.92

Tested by

no test coverage detected