MCPcopy Create free account
hub / github.com/cli/cli / TestGetJobRequiresRepoAndJobID

Function TestGetJobRequiresRepoAndJobID

pkg/cmd/agent-task/capi/job_test.go:26–36  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

24}
25
26func TestGetJobRequiresRepoAndJobID(t *testing.T) {
27 client := &CAPIClient{}
28 _, err := client.GetJob(context.Background(), "", "", "only-job-id")
29 assert.EqualError(t, err, "owner, repo, and jobID are required")
30 _, err = client.GetJob(context.Background(), "", "only-repo", "")
31 assert.EqualError(t, err, "owner, repo, and jobID are required")
32 _, err = client.GetJob(context.Background(), "only-owner", "", "")
33 assert.EqualError(t, err, "owner, repo, and jobID are required")
34 _, err = client.GetJob(context.Background(), "", "", "")
35 assert.EqualError(t, err, "owner, repo, and jobID are required")
36}
37
38func TestGetJob(t *testing.T) {
39 sampleDateString := "2025-08-29T00:00:00Z"

Callers

nothing calls this directly

Calls 1

GetJobMethod · 0.95

Tested by

no test coverage detected