From: Junio C Hamano Date: Wed, 27 Oct 2010 22:35:54 GMT Subject: Re: [PATCHv6 4/6] add tests of commit --fixup Message-ID: <7vk4l3b6wl.fsf@alter.siamese.dyndns.org> In-Reply-To: <1287689637-95301-5-git-send-email-patnotz@gmail.com> "Pat Notz" writes: > diff --git a/t/t3900-i18n-commit.sh b/t/t3900-i18n-commit.sh > index 256c4c9..f9a26c8 100755 > --- a/t/t3900-i18n-commit.sh > +++ b/t/t3900-i18n-commit.sh > @@ -133,4 +133,31 @@ do > ' > done > > +test_commit_autosquash_flags () { > + H=$1 > + flag=$2 > + test_expect_success "commit --$flag with $H encoding" ' > + git config i18n.commitencoding $H && > + git checkout -b $H-$flag C0 && > + echo $H >>F && > + git commit -a -F "$TEST_DIRECTORY"/t3900/$H.txt && > + test_tick && > + echo intermediate stuff >>G && > + git add G && > + git commit -a -m "intermediate commit" && > + test_tick && > + echo $H $flag >>F && > + git commit -a --$flag HEAD~1 $3 && > + E=$(git cat-file commit '$H-$flag' | \ > + sed -ne "s/^encoding //p") && > + test "z$E" = "z'$H'" && A few nits. - You don't need that backslash after the pipe (with the vertical bar at the end of line the shell knows you haven't finished your statement). - I am not sure what the single-quote around only the last two occurrence of $H are about. H and flag are used as part of branch name, so I suspect you do not need any quoting around them, no?