(subcommandsToRemove ...string)
| 20 | ) |
| 21 | |
| 22 | func labelSubcommands(subcommandsToRemove ...string) []TableEntry { |
| 23 | all := []string{ |
| 24 | "app", |
| 25 | "buildpack", |
| 26 | "domain", |
| 27 | "org", |
| 28 | "route", |
| 29 | "space", |
| 30 | "stack", |
| 31 | "service-broker", |
| 32 | "service-instance", |
| 33 | "service-offering", |
| 34 | "service-plan", |
| 35 | } |
| 36 | var entries []TableEntry |
| 37 | for _, labelSubcommand := range all { |
| 38 | remove := false |
| 39 | for _, subCommand := range subcommandsToRemove { |
| 40 | if labelSubcommand == subCommand { |
| 41 | remove = true |
| 42 | break |
| 43 | } |
| 44 | } |
| 45 | if !remove { |
| 46 | entries = append(entries, Entry(labelSubcommand, labelSubcommand)) |
| 47 | } |
| 48 | } |
| 49 | return entries |
| 50 | } |
| 51 | |
| 52 | var _ = Describe("LabelUpdater", func() { |
| 53 | var ( |
no outgoing calls
no test coverage detected