diff --git a/niri-config/tests/wiki-parses.rs b/niri-config/tests/wiki-parses.rs index 9c03b471..ca7e9b75 100644 --- a/niri-config/tests/wiki-parses.rs +++ b/niri-config/tests/wiki-parses.rs @@ -1,19 +1,18 @@ use std::fs; use std::path::PathBuf; -const NO_TEST_COMMENT: &str = ""; - struct KdlCodeBlock { filename: String, code: String, line_number: usize, + must_fail: bool, } fn extract_kdl_from_file(file_contents: &str, filename: &str) -> Vec { - // Removes the > from callouts that might contain ```kdl``` - let lines: Vec<_> = file_contents + let mut lines = file_contents .lines() .map(|line| { + // Removes the > from callouts that might contain ```kdl``` let line = line.trim(); if line.starts_with(">") { if line.len() == 1 { @@ -25,22 +24,18 @@ fn extract_kdl_from_file(file_contents: &str, filename: &str) -> Vec Vec