From 18802ebe41eb88688c6619b3a975b73d2823baea Mon Sep 17 00:00:00 2001 From: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com> Date: Fri, 17 Apr 2020 10:34:58 +0200 Subject: revert tidy tests changes Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com> --- xtask/tests/tidy-tests/main.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'xtask') diff --git a/xtask/tests/tidy-tests/main.rs b/xtask/tests/tidy-tests/main.rs index ead642acc..101ae19bd 100644 --- a/xtask/tests/tidy-tests/main.rs +++ b/xtask/tests/tidy-tests/main.rs @@ -35,7 +35,7 @@ fn check_todo(path: &Path, text: &str) { } if text.contains("TODO") || text.contains("TOOD") || text.contains("todo!") { panic!( - "\nTODO markers or todo! macros should not be committed to the master branch,\n\ + "\nTODO markers should not be committed to the master branch,\n\ use FIXME instead\n\ {}\n", path.display(), @@ -47,9 +47,9 @@ fn check_trailing_ws(path: &Path, text: &str) { if is_exclude_dir(path, &["test_data"]) { return; } - for (line_number, line) in text.lines().enumerate() { + for line in text.lines() { if line.chars().last().map(char::is_whitespace) == Some(true) { - panic!("Trailing whitespace in {} at line {}", path.display(), line_number) + panic!("Trailing whitespace in {}", path.display()) } } } -- cgit v1.2.3