From: Tomas Carnecky <tom@dbservice.com>
To: Thomas Rast <trast@student.ethz.ch>
Cc: git@vger.kernel.org, Junio C Hamano <gitster@pobox.com>,
Adam Mercer <ramercer@gmail.com>
Subject: Re: [PATCH] filter-branch tests/docs: avoid \t in sed regexes
Date: Thu, 29 Jul 2010 17:02:40 +0200 [thread overview]
Message-ID: <4C519810.6090108@dbservice.com> (raw)
In-Reply-To: <201007291652.52506.trast@student.ethz.ch>
On 7/29/10 4:52 PM, Thomas Rast wrote:
> Tomas Carnecky wrote:
>> *** t7003-filter-branch.sh ***
>> * ok 17: use index-filter to move into a subdirectory
>
> Oh, I know. The test isn't correct, it should be something like the
> patch below. Otherwise a failure in git-diff (namely that
> directorymoved:newsubdir is invalid) is never detected, and since the
> output in this case is empty, also the test -z succeeds. Can you
> apply that and see if it makes the test fail for you?
>
> diff --git i/t/t7003-filter-branch.sh w/t/t7003-filter-branch.sh
> index e90da6d..a8e0c48 100755
> --- i/t/t7003-filter-branch.sh
> +++ w/t/t7003-filter-branch.sh
> @@ -148,7 +148,9 @@ test_expect_success 'use index-filter to move into a subdirectory' '
> GIT_INDEX_FILE=\$GIT_INDEX_FILE.new \
> git update-index --index-info &&
> mv \"\$GIT_INDEX_FILE.new\" \"\$GIT_INDEX_FILE\"" directorymoved &&
> - test -z "$(git diff HEAD directorymoved:newsubdir)"'
> + git diff HEAD directorymoved:newsubdir > actual &&
> + test ! -s actual
> +'
>
> test_expect_success 'stops when msg filter fails' '
> old=$(git rev-parse HEAD) &&
Now the test fails. And with the other patch applied on top of it, the
test passes again.
tom
next prev parent reply other threads:[~2010-07-29 15:03 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-29 12:37 Using filter-branch to move repo contents in subdirectory Adam Mercer
2010-07-29 13:08 ` Thomas Rast
2010-07-29 13:15 ` Adam Mercer
2010-07-29 13:24 ` [PATCH] filter-branch tests/docs: avoid \t in sed regexes Thomas Rast
2010-07-29 14:47 ` Tomas Carnecky
2010-07-29 14:52 ` Thomas Rast
2010-07-29 15:02 ` Tomas Carnecky [this message]
2010-07-29 15:10 ` [PATCH] t7005: fix subdirectory-filter test Thomas Rast
2010-07-29 15:12 ` Thomas Rast
2010-08-09 19:36 ` Using filter-branch to move repo contents in subdirectory Adam Mercer
2010-08-11 15:01 ` Adam Mercer
2010-08-11 19:32 ` Jeff King
2010-08-11 19:59 ` Adam Mercer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4C519810.6090108@dbservice.com \
--to=tom@dbservice.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=ramercer@gmail.com \
--cc=trast@student.ethz.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.