diff --git a/loco-new/tests/assertion/string.rs b/loco-new/tests/assertion/string.rs index bc148ce60..585fe869a 100644 --- a/loco-new/tests/assertion/string.rs +++ b/loco-new/tests/assertion/string.rs @@ -6,7 +6,8 @@ pub fn assert_line_regex(content: &str, expected: &str) { // Use assert! to check the regex match and panic if it fails assert!( - re.is_match(content), + // sanitize windows crlf + re.is_match(&content.replace('\r', "")), "Assertion failed: The content did not match the expected string. Expected: '{expected}', \ content:\n{content}" );