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

Function Test_getRepoVisibilityOptions

pkg/cmd/repo/create/create_test.go:1135–1157  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

1133}
1134
1135func Test_getRepoVisibilityOptions(t *testing.T) {
1136 tests := []struct {
1137 name string
1138 owner string
1139 want []string
1140 }{
1141 {
1142 name: "user repo",
1143 owner: "",
1144 want: []string{"Public", "Private"},
1145 },
1146 {
1147 name: "org repo",
1148 owner: "fooOrg",
1149 want: []string{"Public", "Private", "Internal"},
1150 },
1151 }
1152 for _, tt := range tests {
1153 t.Run(tt.name, func(t *testing.T) {
1154 assert.Equal(t, tt.want, getRepoVisibilityOptions(tt.owner))
1155 })
1156 }
1157}

Callers

nothing calls this directly

Calls 3

getRepoVisibilityOptionsFunction · 0.85
EqualMethod · 0.80
RunMethod · 0.65

Tested by

no test coverage detected