git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH 1/4] t5411: start using the default branch name "main"
Date: Wed, 28 Oct 2020 13:00:48 -0700	[thread overview]
Message-ID: <xmqqa6w69l3j.fsf@gitster.c.googlers.com> (raw)
In-Reply-To: <f997166db4c29d971a2343f70c9d9a0505a8cc4b.1603839487.git.gitgitgadget@gmail.com> (Johannes Schindelin via GitGitGadget's message of "Tue, 27 Oct 2020 22:58:04 +0000")

"Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>
writes:

> From: Johannes Schindelin <johannes.schindelin@gmx.de>
>
> This is a straight-forward search-and-replace in the test script;
> However, this is not yet complete because it requires many more
> replacements in `t/t5411/`, too many for a single patch (the Git mailing
> list rejects mails larger than 100kB). For that reason, we disable this
> test script temporarily via the `PREPARE_FOR_MAIN_BRANCH` prereq.

I do not think it matters too much, as it will become correct at the
end anyway, but ... 

> +test_have_prereq PREPARE_FOR_MAIN_BRANCH || {
> +	test_skip="In transit for the default branch name 'main'"
> +	test_done
> +}
> +

... the way I read the introductory paragraph in the proposed log
message is that the point of adding a protection here (done in order
to work around a transient failure caused by having to artificially
split this topic into four patches) is to avoid an inevitable
failure due to some parts of tests adjusted for 'main' while other
parts still expect 'master'.  Until files in t/5411/* gets adjusted
for 'main', nothing is expected to pass whether the default branch
is 'master' or 'main'.  Or with only 1/4 applied, is this test
expected to pass if GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME is set to
'main' (i.e. PREPARE_FOR_MAIN_BRANCH prerequisite is satisfied)?

IOW, I do not see the point in _conditionally_ skipping the rest of
the test in this step.  I'd however understand it if we always skip
the rest in 1/4 and then enable the rest only when testing with
'main' as the default in 4/4, when all the necessary pieces in
t/t5411 have been converted.

The "straight-forward search-and-replace" part looks obviously good,
of course.

Thanks.

>  . "$TEST_DIRECTORY"/t5411/common-functions.sh
>  
>  setup_upstream_and_workbench () {
> -	# Refs of upstream : master(A)
> -	# Refs of workbench: master(A)  tags/v123
> +	# Refs of upstream : main(A)
> +	# Refs of workbench: main(A)  tags/v123
>  	test_expect_success "setup upstream and workbench" '
>  		rm -rf upstream.git &&
>  		rm -rf workbench &&
> @@ -25,10 +30,10 @@ setup_upstream_and_workbench () {
>  			git config core.abbrev 7 &&
>  			git tag -m "v123" v123 $A &&
>  			git remote add origin ../upstream.git &&
> -			git push origin master &&
> -			git update-ref refs/heads/master $A $B &&
> +			git push origin main &&
> +			git update-ref refs/heads/main $A $B &&
>  			git -C ../upstream.git update-ref \
> -				refs/heads/master $A $B
> +				refs/heads/main $A $B
>  		) &&
>  		TAG=$(git -C workbench rev-parse v123) &&
>  
> @@ -99,8 +104,8 @@ start_httpd
>  # Re-initialize the upstream repository and local workbench.
>  setup_upstream_and_workbench
>  
> -# Refs of upstream : master(A)
> -# Refs of workbench: master(A)  tags/v123
> +# Refs of upstream : main(A)
> +# Refs of workbench: main(A)  tags/v123
>  test_expect_success "setup for HTTP protocol" '
>  	git -C upstream.git config http.receivepack true &&
>  	upstream="$HTTPD_DOCUMENT_ROOT_PATH/upstream.git" &&

  reply	other threads:[~2020-10-29  2:04 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-27 22:58 [PATCH 0/4] Adjust t5411 for the upcoming change of the default branch name Johannes Schindelin via GitGitGadget
2020-10-27 22:58 ` [PATCH 1/4] t5411: start using the default branch name "main" Johannes Schindelin via GitGitGadget
2020-10-28 20:00   ` Junio C Hamano [this message]
2020-10-28 20:12     ` Junio C Hamano
2020-10-30 15:04       ` Johannes Schindelin
2020-10-30 17:06         ` Junio C Hamano
2020-10-27 22:58 ` [PATCH 2/4] t5411: start adjusting the support files for init.defaultBranch=main Johannes Schindelin via GitGitGadget
2020-10-27 22:58 ` [PATCH 3/4] t5411: adjust the remaining " Johannes Schindelin via GitGitGadget
2020-10-27 22:58 ` [PATCH 4/4] t5411: finish preparing for `main` being the default branch name Johannes Schindelin via GitGitGadget
2020-10-31 19:45 ` [PATCH v2 0/4] Adjust t5411 for the upcoming change of " Johannes Schindelin via GitGitGadget
2020-10-31 19:46   ` [PATCH v2 1/4] t5411: start using the default branch name "main" Johannes Schindelin via GitGitGadget
2020-10-31 19:46   ` [PATCH v2 2/4] t5411: start adjusting the support files for init.defaultBranch=main Johannes Schindelin via GitGitGadget
2020-10-31 19:46   ` [PATCH v2 3/4] t5411: adjust the remaining " Johannes Schindelin via GitGitGadget
2020-10-31 19:46   ` [PATCH v2 4/4] t5411: finish preparing for `main` being the default branch name Johannes Schindelin via GitGitGadget

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=xmqqa6w69l3j.fsf@gitster.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=johannes.schindelin@gmx.de \
    /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).