Skip to content

Commit

Permalink
make tarpaulin happy
Browse files Browse the repository at this point in the history
  • Loading branch information
gi8lino committed Mar 19, 2023
1 parent 71eb73e commit b02dd47
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions src/args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,7 @@ impl Args {
.add(Filter::Variable, arg, value, &mut args)?;
}
// UNKNOWN
_ => {
return Err(ParseArgsError::UnknownFlag(arg.to_string()));
}
_ => return Err(ParseArgsError::UnknownFlag(arg.to_string())),
}
}

Expand Down Expand Up @@ -193,17 +191,6 @@ mod tests {
);
}

#[test]
fn test_parse_unknown_flag2() {
let args = vec!["--unknown-flag"];
let parsed_args = Args::parse(args);
assert!(parsed_args.is_err());
assert_eq!(
parsed_args.unwrap_err(),
ParseArgsError::UnknownFlag("--unknown-flag".to_owned())
);
}

#[test]
fn test_parse_help_flag() {
let args = vec!["-h"];
Expand Down

0 comments on commit b02dd47

Please sign in to comment.