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

Function Test_ActionsGetJobLogs

pkg/github/actions_test.go:528–546  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

526}
527
528func Test_ActionsGetJobLogs(t *testing.T) {
529 // Verify tool definition once
530 toolDef := ActionsGetJobLogs(translations.NullTranslationHelper)
531
532 // Note: consolidated ActionsGetJobLogs has same tool name "get_job_logs" as the individual tool
533 // but with different descriptions. We skip toolsnap validation here since the individual
534 // tool's toolsnap already exists and is tested in Test_GetJobLogs.
535 // The consolidated tool has FeatureFlagEnable set, so only one will be active at a time.
536 assert.Equal(t, "get_job_logs", toolDef.Tool.Name)
537 assert.NotEmpty(t, toolDef.Tool.Description)
538 inputSchema := toolDef.Tool.InputSchema.(*jsonschema.Schema)
539 assert.Contains(t, inputSchema.Properties, "owner")
540 assert.Contains(t, inputSchema.Properties, "repo")
541 assert.Contains(t, inputSchema.Properties, "job_id")
542 assert.Contains(t, inputSchema.Properties, "run_id")
543 assert.Contains(t, inputSchema.Properties, "failed_only")
544 assert.Contains(t, inputSchema.Properties, "return_content")
545 assert.ElementsMatch(t, inputSchema.Required, []string{"owner", "repo"})
546}
547
548func Test_ActionsGetJobLogs_SingleJob(t *testing.T) {
549 toolDef := ActionsGetJobLogs(translations.NullTranslationHelper)

Callers

nothing calls this directly

Calls 1

ActionsGetJobLogsFunction · 0.85

Tested by

no test coverage detected