-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test(mangen): Add all flatten related tests from builder
Add all tests from tests/builder/help.rs to mangen, too. Signed-off-by: Paul Spooren <[email protected]>
- Loading branch information
Showing
13 changed files
with
653 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR <\fB\-\-parent\fR> [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent test\fR <\fB\-\-child\fR> [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR <\fB\-\-child\fR> [\fB\-h\fR|\fB\-\-help\fR] | ||
test command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent test\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
test command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent test\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
bar | ||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help (see a summary with \*(Aq\-h\*(Aq) | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
long some | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child2\fR [\fB\-\-child2\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child3\fR [\fB\-\-child3\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBchild1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child1 command | ||
.TP | ||
\fBchild2\fR [\fB\-\-child2\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child2 command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child2\fR [\fB\-\-child2\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child3\fR [\fB\-\-child3\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBchild1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child1 command | ||
.TP | ||
\fBchild2\fR [\fB\-\-child2\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child2 command | ||
.TP | ||
\fBchild3\fR [\fB\-\-child3\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child3 command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child2\fR [\fB\-\-child2\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child3\fR [\fB\-\-child3\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBchild1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child1 command | ||
.TP | ||
\fBchild2\fR [\fB\-\-child2\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
child2 command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
24 changes: 24 additions & 0 deletions
24
clap_mangen/tests/snapshots/flatten_single_hidden_command.roff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent child1\fR [\fB\-\-child1\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
27 changes: 27 additions & 0 deletions
27
clap_mangen/tests/snapshots/flatten_with_args_conflicts_with_subcommands.roff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent test\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
test command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
27 changes: 27 additions & 0 deletions
27
clap_mangen/tests/snapshots/flatten_with_external_subcommand.roff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent test\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
test command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent test\fR [\fB\-\-child\fR] [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR [\fB\-\-child\fR] [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
test command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
25 changes: 25 additions & 0 deletions
25
clap_mangen/tests/snapshots/flatten_with_subcommand_required.roff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent test\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.br | ||
\fBparent help\fR | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help | ||
.SH SUBCOMMANDS | ||
.TP | ||
\fBtest\fR [\fB\-\-child\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
test command | ||
.TP | ||
\fBhelp\fR | ||
Print this message or the help of the given subcommand(s) |
16 changes: 16 additions & 0 deletions
16
clap_mangen/tests/snapshots/flatten_without_subcommands.roff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
.ie \n(.g .ds Aq \(aq | ||
.el .ds Aq ' | ||
.TH parent 1 "parent " | ||
.SH NAME | ||
parent \- parent command | ||
.SH SYNOPSIS | ||
\fBparent\fR [\fB\-\-parent\fR] [\fB\-h\fR|\fB\-\-help\fR] | ||
.SH DESCRIPTION | ||
parent command | ||
.SH OPTIONS | ||
.TP | ||
\fB\-\-parent\fR | ||
|
||
.TP | ||
\fB\-h\fR, \fB\-\-help\fR | ||
Print help |
Oops, something went wrong.