]> Sergey Matveev's repositories - public-inbox.git/blobdiff - t/hval.t
hval: add src_escape for highlight post-processing
[public-inbox.git] / t / hval.t
index a193c296649094cb67263017aa438495c9cbcf3a..bfc9a856f50ba83886388f34e57ad1f3fa91ddbe 100644 (file)
--- a/t/hval.t
+++ b/t/hval.t
@@ -43,5 +43,8 @@ is('foo-bar', PublicInbox::Hval::to_filename("foo   bar\nanother line\n"),
 is('foo.bar', PublicInbox::Hval::to_filename("foo....bar"),
        'to_filename squeezes -');
 
+my $s = "\0\x07\n";
+PublicInbox::Hval::src_escape($s);
+is($s, "\\0\\a\n", 'src_escape works as intended');
 
 done_testing();