Merge branch 'sb/prepare-revision-walk-error-check'
[gitweb.git] / t / t4205-log-pretty-formats.sh
index c84ec9ae6139be752831365244f5580e46138884..de0cc4a0fd5fe37bb36a3268182d95de3589f4b4 100755 (executable)
@@ -31,7 +31,7 @@ test_expect_success 'set up basic repos' '
        git add foo &&
        test_tick &&
        git config i18n.commitEncoding $test_encoding &&
-       git commit -m "$(commit_msg $test_encoding)" &&
+       commit_msg $test_encoding | git commit -F - &&
        git add bar &&
        test_tick &&
        git commit -m "add bar" &&
@@ -431,6 +431,13 @@ EOF
        test_cmp expected actual
 '
 
+test_expect_success 'strbuf_utf8_replace() not producing NUL' '
+       git log --color --pretty="tformat:%<(10,trunc)%s%>>(10,ltrunc)%C(auto)%d" |
+               test_decode_color |
+               nul_to_q >actual &&
+       ! grep Q actual
+'
+
 # get new digests (with no abbreviations)
 head1=$(git rev-parse --verify HEAD~0) &&
 head2=$(git rev-parse --verify HEAD~1) &&