mirror of
https://github.com/sharkdp/bat.git
synced 2025-09-01 10:52:24 +01:00
Fix clippy::needless_borrows_for_generic_args
warnings
This commit is contained in:
@@ -1832,7 +1832,7 @@ fn do_not_panic_regression_tests() {
|
||||
] {
|
||||
bat()
|
||||
.arg("--color=always")
|
||||
.arg(&format!("regression_tests/{filename}"))
|
||||
.arg(format!("regression_tests/{filename}"))
|
||||
.assert()
|
||||
.success();
|
||||
}
|
||||
@@ -1845,7 +1845,7 @@ fn do_not_detect_different_syntax_for_stdin_and_files() {
|
||||
let cmd_for_file = bat()
|
||||
.arg("--color=always")
|
||||
.arg("--map-syntax=*.js:Markdown")
|
||||
.arg(&format!("--file-name={file}"))
|
||||
.arg(format!("--file-name={file}"))
|
||||
.arg("--style=plain")
|
||||
.arg(file)
|
||||
.assert()
|
||||
@@ -1855,7 +1855,7 @@ fn do_not_detect_different_syntax_for_stdin_and_files() {
|
||||
.arg("--color=always")
|
||||
.arg("--map-syntax=*.js:Markdown")
|
||||
.arg("--style=plain")
|
||||
.arg(&format!("--file-name={file}"))
|
||||
.arg(format!("--file-name={file}"))
|
||||
.pipe_stdin(Path::new(EXAMPLES_DIR).join(file))
|
||||
.unwrap()
|
||||
.assert()
|
||||
@@ -1874,7 +1874,7 @@ fn no_first_line_fallback_when_mapping_to_invalid_syntax() {
|
||||
bat()
|
||||
.arg("--color=always")
|
||||
.arg("--map-syntax=*.invalid-syntax:InvalidSyntax")
|
||||
.arg(&format!("--file-name={file}"))
|
||||
.arg(format!("--file-name={file}"))
|
||||
.arg("--style=plain")
|
||||
.arg(file)
|
||||
.assert()
|
||||
|
Reference in New Issue
Block a user