Re: [PATCH 1/2] t2200: check that "add -u" limits itself to subdirectory
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Mar 13, 2013, 17:44 UTC
- Message-ID
- <7vli9r2o06.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <20130313041022.GA5378@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
> We didn't seem to be testing this transition at all. I think it's sane > to do so now, and Junio's "now it is 2.0, let's switch" patch should > update the test.
Yes, but I am not sure if this is testing the right thing.
Show 10 quoted lines
> +# Note that this is scheduled to change in Git 2.0, when > +# "git add -u" will become full-tree by default. > +test_expect_success 'update did not touch files at root' ' > + cat >expect <<-\EOF && > + check > + top > + EOF > + git diff-files --name-only >actual && > + test_cmp expect actual > +'
The last "git add -u" we have beforet his block is this test piece:
test_expect_success 'update from a subdirectory' '
(
cd dir1 &&
echo more >sub2 &&
git add -u sub2
)
'That is not "git add -u" without pathspec, which is the only thing we are transitioning at Git 2.0 boundary.