Test escape sequences between single quotes

This commit is contained in:
Colin Benner 2018-10-04 11:34:27 +02:00
parent 72a4e8e01f
commit 94de4c033a

View file

@ -486,3 +486,9 @@ fn test_digits() {
"approx. 7.11801620446533345187845043255947530269622802734375 (dimensionless)",
);
}
#[test]
fn test_escapes() {
test("'ab\\'cd\\n\\t'", "1 ab'cd\n\t (ab'cd\n\t)");
test("'x\\a'", "Expected term, got <Invalid escape sequence \\a>");
}