diff --git a/src/properties.rs b/src/properties.rs index f8fa373..ba8292e 100644 --- a/src/properties.rs +++ b/src/properties.rs @@ -439,6 +439,14 @@ mod tests { assert_eq!(expected, fold_line(line)); } + #[test] + fn escape_special_characters_in_text() { + let line = r"\n\;,:"; + + let expected = r"\\n\\\;\,:"; + assert_eq!(expected, Property::escape_text(line)); + } + #[cfg(feature = "parser")] #[test] fn preserve_spaces() {