From: Eric Sunshine Date: Tue, 16 Dec 2014 19:37:23 GMT Subject: Re: [PATCHv2 6/6] t5543-atomic-push.sh: add basic tests for atomic pushes Message-ID: In-Reply-To: <1418755747-22506-6-git-send-email-sbeller@google.com> On Tue, Dec 16, 2014 at 1:49 PM, Stefan Beller wrote: > This adds tests for the atomic push option. > The first four tests check if the atomic option works in > good conditions and the last three patches check if the atomic > option prevents any change to be pushed if just one ref cannot > be updated. > > Signed-off-by: Stefan Beller > --- > diff --git a/t/t5543-atomic-push.sh b/t/t5543-atomic-push.sh > new file mode 100755 > index 0000000..6354fc0 > --- /dev/null > +++ b/t/t5543-atomic-push.sh > @@ -0,0 +1,176 @@ > +#!/bin/sh > + > +test_description='pushing to a repository using the atomic push option' > + > +. ./test-lib.sh > + > +D=`pwd` Junio already mentioned this previously, but this should be $(pwd) rather than `pwd`. However, more importantly, why is this variable declared at all since it is never used by the script? > +mk_repo_pair () { > + rm -rf workbench upstream && > + test_create_repo upstream && > + test_create_repo workbench && > + ( > + cd upstream && git config receive.denyCurrentBranch warn This would be slightly easier to read if split over two lines. > + ) && > + ( > + cd workbench && git remote add up ../upstream Ditto. > + ) > +} > +