| 13 | ) |
| 14 | |
| 15 | func TestGetJobRequiresRepoAndJobID(t *testing.T) { |
| 16 | client := &CAPIClient{} |
| 17 | _, err := client.GetJob(context.Background(), "", "", "only-job-id") |
| 18 | assert.EqualError(t, err, "owner, repo, and jobID are required") |
| 19 | _, err = client.GetJob(context.Background(), "", "only-repo", "") |
| 20 | assert.EqualError(t, err, "owner, repo, and jobID are required") |
| 21 | _, err = client.GetJob(context.Background(), "only-owner", "", "") |
| 22 | assert.EqualError(t, err, "owner, repo, and jobID are required") |
| 23 | _, err = client.GetJob(context.Background(), "", "", "") |
| 24 | assert.EqualError(t, err, "owner, repo, and jobID are required") |
| 25 | } |
| 26 | |
| 27 | func TestGetJob(t *testing.T) { |
| 28 | sampleDateString := "2025-08-29T00:00:00Z" |