diff options
Diffstat (limited to 'src/bin/r2md-append.rs')
| -rw-r--r-- | src/bin/r2md-append.rs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/bin/r2md-append.rs b/src/bin/r2md-append.rs index 4cd2ae9..4dd0698 100644 --- a/src/bin/r2md-append.rs +++ b/src/bin/r2md-append.rs @@ -47,4 +47,23 @@ mod tests { vec![OsString::from("README.md"), OsString::from("src/main.rs")] ); } + + #[test] + fn treats_arguments_after_double_dash_as_paths() { + let cli = Cli::try_parse_from([ + "r2md-append", + "--", + "--filename-that-looks-like-an-option", + "main.rs", + ]) + .unwrap(); + + assert_eq!( + cli.paths, + vec![ + OsString::from("--filename-that-looks-like-an-option"), + OsString::from("main.rs") + ] + ); + } } |
