Deprecate HelpFormatter.

This commit is contained in:
Alec Thomas
2021-12-03 11:47:34 +11:00
parent c3703cda7e
commit c5e464a367
3 changed files with 13 additions and 3 deletions
+2 -2
View File
@@ -477,7 +477,7 @@ func TestEnvarAutoHelpWithEnvPrefix(t *testing.T) {
require.Contains(t, w.String(), "A different flag.")
}
func TestCustomHelpFormatter(t *testing.T) {
func TestCustomValueFormatter(t *testing.T) {
var cli struct {
Flag string `env:"FLAG" help:"A flag."`
}
@@ -485,7 +485,7 @@ func TestCustomHelpFormatter(t *testing.T) {
p := mustNew(t, &cli,
kong.Writers(w, w),
kong.Exit(func(int) {}),
kong.HelpFormatter(func(value *kong.Value) string {
kong.ValueFormatter(func(value *kong.Value) string {
return value.Help
}),
)