(t *testing.T)
| 72 | } |
| 73 | |
| 74 | func TestProgWithColon(t *testing.T) { |
| 75 | rootCmd := &Command{Use: "root:colon", Args: NoArgs, Run: emptyRun} |
| 76 | buf := new(bytes.Buffer) |
| 77 | assertNoErr(t, rootCmd.GenFishCompletion(buf, false)) |
| 78 | output := buf.String() |
| 79 | |
| 80 | // Functions name should have replace the ':' |
| 81 | check(t, output, "__root_colon_perform_completion") |
| 82 | checkOmit(t, output, "__root:colon_perform_completion") |
| 83 | |
| 84 | // The command name should not have replaced the ':' |
| 85 | check(t, output, "-c root:colon") |
| 86 | checkOmit(t, output, "-c root_colon") |
| 87 | } |
| 88 | |
| 89 | func TestFishCompletionNoActiveHelp(t *testing.T) { |
| 90 | c := &Command{Use: "c", Run: emptyRun} |
nothing calls this directly
no test coverage detected