git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "SZEDER Gábor" <szeder.dev@gmail.com>
To: Jonathan Tan <jonathantanmy@google.com>
Cc: git@vger.kernel.org, newren@gmail.com
Subject: Re: [RFC PATCH] merge-recursive: symlink's descendants not in way
Date: Wed, 18 Sep 2019 01:02:24 +0200	[thread overview]
Message-ID: <20190917230224.GB29845@szeder.dev> (raw)
In-Reply-To: <20190917215040.132503-1-jonathantanmy@google.com>

On Tue, Sep 17, 2019 at 02:50:40PM -0700, Jonathan Tan wrote:
> diff --git a/t/t3030-merge-recursive.sh b/t/t3030-merge-recursive.sh
> index ff641b348a..dfd617a845 100755
> --- a/t/t3030-merge-recursive.sh
> +++ b/t/t3030-merge-recursive.sh
> @@ -452,6 +452,33 @@ test_expect_success 'merge-recursive d/f conflict result' '
>  
>  '
>  
> +test_expect_success 'dir in working tree with symlink ancestor does not produce d/f conflict' '

This test needs the SYMLINKS prereq.

> +	git init sym &&
> +	(
> +		cd sym &&
> +		ln -s . foo &&
> +		mkdir bar &&
> +		touch bar/file &&

Nit: >bar/file (though because of the symlink this test won't be run
on the most fork()-challenged platform).

> +		git add foo bar/file &&
> +		git commit -m "foo symlink" &&
> +
> +		git checkout -b branch1 &&
> +		git commit --allow-empty -m "empty commit" &&
> +
> +		git checkout master &&
> +		git rm foo &&
> +		mkdir foo &&
> +		touch foo/bar &&
> +		git add foo/bar &&
> +		git commit -m "replace foo symlink with real foo dir and foo/bar file" &&
> +
> +		git checkout branch1 &&
> +
> +		# Exercise to make sure that this works without errors
> +		git cherry-pick master

Working without errors is great, but I think this test should also
check that the results are as expected, e.g. 'foo' is now a directory,
etc.

> +	)
> +'
> +
>  test_expect_success 'reset and 3-way merge' '
>  
>  	git reset --hard "$c2" &&
> -- 
> 2.23.0.237.gc6a4ce50a0-goog
> 

  parent reply	other threads:[~2019-09-17 23:02 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-16 21:47 merge-recursive thinks symlink's child dirs are "real" Jonathan Tan
2019-09-16 22:15 ` SZEDER Gábor
2019-09-17 15:54   ` Elijah Newren
2019-09-17  0:09 ` Jonathan Nieder
2019-09-17 16:02   ` Elijah Newren
2019-09-17 15:48 ` Elijah Newren
2019-09-17 21:50   ` [RFC PATCH] merge-recursive: symlink's descendants not in way Jonathan Tan
2019-09-17 22:23     ` Junio C Hamano
2019-09-17 22:32       ` Jonathan Tan
2019-09-17 22:37         ` Junio C Hamano
2019-09-17 22:49           ` Jonathan Tan
2019-09-17 23:02     ` SZEDER Gábor [this message]
2019-09-18  0:35     ` Elijah Newren

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190917230224.GB29845@szeder.dev \
    --to=szeder.dev@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=jonathantanmy@google.com \
    --cc=newren@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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).