From: Junio C Hamano <gitster@pobox.com>
To: "Michał Kiedrowicz" <michal.kiedrowicz@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: [PATCH] tests: test applying criss-cross rename patch
Date: Mon, 13 Apr 2009 09:47:19 -0700 [thread overview]
Message-ID: <7vd4bgh560.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <1239463584-1427-1-git-send-email-michal.kiedrowicz@gmail.com> (Michał Kiedrowicz's message of "Sat, 11 Apr 2009 17:26:24 +0200")
Michał Kiedrowicz <michal.kiedrowicz@gmail.com> writes:
> Signed-off-by: Michał Kiedrowicz <michal.kiedrowicz@gmail.com>
> ---
> t/t4130-apply-criss-cross-rename.sh | 35 +++++++++++++++++++++++++++++++++++
> 1 files changed, 35 insertions(+), 0 deletions(-)
> create mode 100755 t/t4130-apply-criss-cross-rename.sh
>
> diff --git a/t/t4130-apply-criss-cross-rename.sh b/t/t4130-apply-criss-cross-rename.sh
> new file mode 100755
> index 0000000..30187ff
> --- /dev/null
> +++ b/t/t4130-apply-criss-cross-rename.sh
> @@ -0,0 +1,35 @@
> +#!/bin/sh
> +
> +test_description='git apply handling criss-cross rename patch.'
> +. ./test-lib.sh
> +
> +create_file() {
> + for ((i=0; i<100; i++)); do
Please don't; isn't this a bashism?
> + echo "$2" >> "$1"
> + done
> +}
> +
> +test_expect_success 'setup' '
> + create_file file1 "File1 contents" &&
> + create_file file2 "File2 contents" &&
> + git add file1 file2 &&
> + git commit -m 1
> +'
> +
> +test_expect_success 'criss-cross rename' '
> + mv file1 tmp &&
> + mv file2 file1 &&
> + mv tmp file2
> +'
> +
> +test_expect_success 'diff -M -B' '
> + git diff -M -B > diff &&
> + git reset --hard
> +
> +'
> +
> +test_expect_failure 'apply' '
> + git apply diff
> +'
> +
> +test_done
> --
> 1.6.0.6
next prev parent reply other threads:[~2009-04-13 16:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-09 18:59 buglet: 'git apply' doesn't handle criss-cross renames Linus Torvalds
2009-04-11 15:26 ` [PATCH] tests: test applying criss-cross rename patch Michał Kiedrowicz
2009-04-13 16:47 ` Junio C Hamano [this message]
2009-04-13 19:28 ` Junio C Hamano
2009-04-20 14:11 ` Alex Riesen
2009-04-21 7:08 ` Junio C Hamano
2009-04-21 12:41 ` Alex Riesen
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=7vd4bgh560.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=michal.kiedrowicz@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).