git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Elijah Newren <newren@gmail.com>
To: gitster@pobox.com
Cc: git@vger.kernel.org, Elijah Newren <newren@gmail.com>
Subject: Re: [PATCH 0/6] Add merge recursive testcases with undetected conflicts
Date: Mon,  9 Jul 2018 13:22:29 -0700	[thread overview]
Message-ID: <20180709202229.10222-1-newren@gmail.com> (raw)
In-Reply-To: <xmqqr2kce1mw.fsf@gitster-ct.c.googlers.com>

On Mon, Jul 9, 2018 at 10:53 AM, Junio C Hamano <gitster@pobox.com> wrote:
> Elijah Newren <newren@gmail.com> writes:
>
>> When a merge succeeds, we expect the resulting contents to depend only
>> upon the trees and blobs of the branches involved and of their merge
>> base(s).  Unfortunately, there are currently about half a dozen cases
>> where the contents of a "successful" merge depend on the relative
>> commit timestamps of the merge bases.  Document these with testcases.
>>
>> (This series came out of looking at modifying how file collision
>> conflict types are handled, as discussed at [1].  I discovered these
>> issues while working on that topic.)
>
> I have a topic branch for this series but not merged to 'pu' as
> test-lint gives these:
>
> t6036-recursive-corner-cases.sh:1222: error: "export FOO=bar" is not portable (please use FOO=bar && export FOO):               echo "export PATH=~/bin:$PATH" >source_me.bash &&
> t6036-recursive-corner-cases.sh:1227: error: "export FOO=bar" is not portable (please use FOO=bar && export FOO):               echo "export PATH=~/bin:$PATH" >source_me.bash &&
> Makefile:77: recipe for target 'test-lint-shell-syntax' failed
> make: *** [test-lint-shell-syntax] Error 1
>
> Arguably these are false positives because "source_me.bash" file is
> a mere payload to go through the merge process to be munged and we
> never intend to actually execute its contents with bash, but then
> the test payload probably does not even have to be a string that
> triggers such a false positive to begin with ;-)

Oh, I didn't know about test-lint.  Is there a place that documents the various checks you run, so I can avoid slowing you down?  Ones I know about:

Already documented:
  * `make DEVELOPER=1` (from CodingGuidelines)
  * running tests (from SubmittingPatches)

Stuff I've seen you mention in emails over time:
  * linux/scripts/checkpatch.pl
  * git grep -e '\<inline\>' --and --not -e 'static inline' -- \*.h
  * make -C t/ test-lint

Are there others?


Also, here's a fixup to the topic; as you pointed out, the exact contents
of the script being written were actually irrelevant; it was just an
input to a merge.

-- 8< --
Subject: [PATCH] fixup! t6036: add a failed conflict detection case: regular
 files, different modes

---
 t/t6036-recursive-corner-cases.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/t/t6036-recursive-corner-cases.sh b/t/t6036-recursive-corner-cases.sh
index f8f7b30460..5a8fe061ab 100755
--- a/t/t6036-recursive-corner-cases.sh
+++ b/t/t6036-recursive-corner-cases.sh
@@ -1219,12 +1219,12 @@ test_expect_success 'setup conflicting modes for regular file' '
 		git tag A &&
 
 		git checkout -b B A &&
-		echo "export PATH=~/bin:$PATH" >source_me.bash &&
+		echo "command_to_run" >source_me.bash &&
 		git add source_me.bash &&
 		git commit -m B &&
 
 		git checkout -b C A &&
-		echo "export PATH=~/bin:$PATH" >source_me.bash &&
+		echo "command_to_run" >source_me.bash &&
 		git add source_me.bash &&
 		test_chmod +x source_me.bash &&
 		git commit -m C &&
-- 
2.18.0.135.gd4ea5491ab


  reply	other threads:[~2018-07-09 20:22 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-01  4:11 [PATCH 0/6] Add merge recursive testcases with undetected conflicts Elijah Newren
2018-07-01  4:11 ` [PATCH 1/6] t6036: add a failed conflict detection case with symlink modify/modify Elijah Newren
2018-07-01  4:11 ` [PATCH 2/6] t6036: add a failed conflict detection case with symlink add/add Elijah Newren
2018-07-01  4:11 ` [PATCH 3/6] t6036: add a failed conflict detection case with submodule modify/modify Elijah Newren
2018-07-01  4:11 ` [PATCH 4/6] t6036: add a failed conflict detection case with submodule add/add Elijah Newren
2018-07-01  4:11 ` [PATCH 5/6] t6036: add a failed conflict detection case with conflicting types Elijah Newren
2018-07-01  4:11 ` [PATCH 6/6] t6036: add a failed conflict detection case: regular files, different modes Elijah Newren
2018-07-09 17:53 ` [PATCH 0/6] Add merge recursive testcases with undetected conflicts Junio C Hamano
2018-07-09 20:22   ` Elijah Newren [this message]
2018-07-10  4:44     ` Jeff King
2018-07-10 15:42       ` Elijah Newren
2018-07-10 17:19         ` Jeff King
2018-07-11  4:02     ` Elijah Newren
2018-07-11 15:40       ` Junio C Hamano

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=20180709202229.10222-1-newren@gmail.com \
    --to=newren@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.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).