MCPcopy Create free account
hub / github.com/github/gh-aw / TestGetRepoDefaultBranch_Integration

Function TestGetRepoDefaultBranch_Integration

pkg/cli/update_integration_test.go:435–441  ·  view source on GitHub ↗

--- Helper Function Tests --- TestGetRepoDefaultBranch_Integration verifies fetching the default branch via GitHub API.

(t *testing.T)

Source from the content-addressed store, hash-verified

433
434// TestGetRepoDefaultBranch_Integration verifies fetching the default branch via GitHub API.
435func TestGetRepoDefaultBranch_Integration(t *testing.T) {
436 skipWithoutGitHubAuth(t)
437
438 branch, err := getRepoDefaultBranch(context.Background(), "actions/checkout")
439 require.NoError(t, err, "Should fetch default branch for actions/checkout")
440 assert.Equal(t, "main", branch, "actions/checkout default branch should be 'main'")
441}
442
443// TestGetLatestBranchCommitSHA_Integration verifies fetching the latest commit SHA for a branch.
444func TestGetLatestBranchCommitSHA_Integration(t *testing.T) {

Callers

nothing calls this directly

Calls 3

skipWithoutGitHubAuthFunction · 0.85
getRepoDefaultBranchFunction · 0.85
BackgroundMethod · 0.80

Tested by

no test coverage detected