From: Eric Sunshine Date: Mon, 14 Mar 2016 21:21:19 GMT Subject: Re: [PATCH v6] commit: add a commit.verbose config variable Message-ID: In-Reply-To: <0102015376e53b40-d25f7fdc-4ae1-4aae-b779-052fcf252071-000000@eu-west-1.amazonses.com> On Mon, Mar 14, 2016 at 4:50 PM, Pranit Bauva wrote: > Add commit.verbose configuration variable as a convenience for those > who always prefer --verbose. > > Helped-by: Eric Sunshine > Signed-off-by: Pranit Bauva > --- > diff --git a/t/t7507-commit-verbose.sh b/t/t7507-commit-verbose.sh > index 2ddf28c..35960b4 100755 > --- a/t/t7507-commit-verbose.sh > +++ b/t/t7507-commit-verbose.sh > @@ -96,4 +96,33 @@ test_expect_success 'verbose diff is stripped out with set core.commentChar' ' > +test_expect_success 'commit.verbose true and --verbose omitted' ' > + git -c commit.verbose=true commit --amend > +' > + > +test_expect_success 'commit.verbose true and --no-verbose' ' > + test_must_fail git -c commit.verbose=true commit --amend --no-verbose > +' > + > +test_expect_success 'commit.verbose false and --verbose' ' > + git -c commit.verbose=false commit --amend --verbose > +' > + > +test_expect_success 'commit.verbose false and --verbose omitted' ' > + test_must_fail git -c commit.verbose=false commit --amend > +' > + > +test_expect_success 'commit.verbose true and --verbose' ' > + git -c commit.verbose=true commit --amend --verbose > +' > + > +test_expect_success 'commit.verbose false and --no-verbose' ' > + test_must_fail git -c commit.verbose=false commit --amend --no-verbose > +' > + > +test_expect_success 'status ignores commit.verbose=true' ' > + git status >actual && This is missing the important "-c commit.verbose=false". Without it, you're not really testing anything interesting. (It was missing in the "something like this" example test I typed directly in the email of my last review[1], which I suppose is a good lesson that "something like this" is not meant as "final" or "trust this".) [1]: http://article.gmane.org/gmane.comp.version-control.git/288774 > + ! grep "^diff --git" actual > +' > + > test_done