git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jacob Keller <jacob.e.keller@intel.com>
Cc: git@vger.kernel.org, Jacob Keller <jacob.keller@gmail.com>
Subject: Re: [PATCH v3] name-rev: use generation numbers if available
Date: Wed, 09 Mar 2022 17:32:29 -0800	[thread overview]
Message-ID: <xmqqa6dyiocy.fsf@gitster.g> (raw)
In-Reply-To: <xmqqilsmir41.fsf@gitster.g> (Junio C. Hamano's message of "Wed, 09 Mar 2022 16:33:02 -0800")

Junio C Hamano <gitster@pobox.com> writes:

>> +test_expect_success 'name-rev with commitGraph handles non-monotonic timestamps' '
>> +	test_config -C non-monotonic core.commitGraph false &&
>
> Don't you mean "true" here?
>
>> +	(
>> +		cd non-monotonic &&
>> +
>> +		echo "main~3 tags/D~2" >expect &&
>> +		git name-rev --tags main~3 >actual &&
>> +
>> +		test_cmp expect actual
>> +	)
>> +'

And I am not sure if there is anybody _writing_ the graph file in
the first place, so perhaps squash this in?

 t/t6120-describe.sh | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/t/t6120-describe.sh b/t/t6120-describe.sh
index 0b18f73779..9a35e783a7 100755
--- a/t/t6120-describe.sh
+++ b/t/t6120-describe.sh
@@ -503,10 +503,12 @@ test_expect_success 'non-monotonic commit dates setup' '
 '
 
 test_expect_success 'name-rev with commitGraph handles non-monotonic timestamps' '
-	test_config -C non-monotonic core.commitGraph false &&
+	test_config -C non-monotonic core.commitGraph true &&
 	(
 		cd non-monotonic &&
 
+		git commit-graph write --reachable &&
+
 		echo "main~3 tags/D~2" >expect &&
 		git name-rev --tags main~3 >actual &&
 
-- 
2.35.1-744-g1f8f0331bc


      parent reply	other threads:[~2022-03-10  1:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-10  0:05 [PATCH v3] name-rev: use generation numbers if available Jacob Keller
2022-03-10  0:33 ` Junio C Hamano
2022-03-10  1:25   ` Keller, Jacob E
2022-03-10  1:32   ` Junio C Hamano [this message]

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=xmqqa6dyiocy.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=jacob.e.keller@intel.com \
    --cc=jacob.keller@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).