mirror of
https://github.com/clap-rs/clap
synced 2024-12-13 14:22:34 +00:00
Revert "Fix test to support env
feature disabled"
This reverts commit 477f884af1
.
This commit is contained in:
parent
b9d007d262
commit
2537894c4b
1 changed files with 3 additions and 3 deletions
|
@ -138,7 +138,7 @@ USAGE:
|
|||
OPTIONS:
|
||||
--first first about
|
||||
-h, --help Print help information
|
||||
-s, --second
|
||||
--second [env: ENV_REPLACED=]
|
||||
--third third arg
|
||||
-V, --version Print version information
|
||||
";
|
||||
|
@ -1257,11 +1257,11 @@ fn partial_mut_args() {
|
|||
.arg(
|
||||
Arg::new("first").long("first").about("first arg"), // this about will be replaced
|
||||
)
|
||||
.arg(Arg::new("second").long("second").short('r')) // this short will be replaced
|
||||
.arg(Arg::new("second").long("second").env("ENV_SECOND")) // this env will be replaced
|
||||
.arg(Arg::new("third").long("third").about("third arg")) // this will not be mutated
|
||||
.mut_args(|v| match v.get_name() {
|
||||
"first" => Some(v.about("first about")),
|
||||
"second" => Some(v.short('s')),
|
||||
"second" => Some(v.env("ENV_REPLACED")),
|
||||
_ => None,
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue