diff mbox series

[v4] tests: modernize the test script t0010-racy-git.sh

Message ID pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com (mailing list archive)
State Accepted
Commit 1605035217e137bc446ce0d64ffa9575dda810ee
Headers show
Series [v4] tests: modernize the test script t0010-racy-git.sh | expand

Commit Message

Aryan Gupta March 6, 2024, 9:14 a.m. UTC
From: Aryan Gupta <garyan447@gmail.com>

Modernize the formatting of the test script to align with current
standards and improve its overall readability.

Signed-off-by: Aryan Gupta <garyan447@gmail.com>
---
    [GSOC][PATCH] Modernize a test script

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1675%2Faryangupta701%2Ftest-modernize-v4
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1675/aryangupta701/test-modernize-v4
Pull-Request: https://github.com/gitgitgadget/git/pull/1675

Range-diff vs v3:

 1:  05ee9e8a458 = 1:  14c7137baea tests: modernize the test script t0010-racy-git.sh


 t/t0010-racy-git.sh | 31 +++++++++++++++----------------
 1 file changed, 15 insertions(+), 16 deletions(-)


base-commit: 3c2a3fdc388747b9eaf4a4a4f2035c1c9ddb26d0

Comments

Christian Couder March 7, 2024, 1:28 p.m. UTC | #1
On Wed, Mar 6, 2024 at 10:46 AM Aryan Gupta via GitGitGadget
<gitgitgadget@gmail.com> wrote:
>
> From: Aryan Gupta <garyan447@gmail.com>
>
> Modernize the formatting of the test script to align with current
> standards and improve its overall readability.
>
> Signed-off-by: Aryan Gupta <garyan447@gmail.com>
> ---
>     [GSOC][PATCH] Modernize a test script
>
> Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1675%2Faryangupta701%2Ftest-modernize-v4
> Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1675/aryangupta701/test-modernize-v4
> Pull-Request: https://github.com/gitgitgadget/git/pull/1675
>
> Range-diff vs v3:
>
>  1:  05ee9e8a458 = 1:  14c7137baea tests: modernize the test script t0010-racy-git.sh

This tells us that nothing changed in the patch since v3, so we can
only wonder why you sent this v4.

Did you fix some headers? Please explain.

>  t/t0010-racy-git.sh | 31 +++++++++++++++----------------
>  1 file changed, 15 insertions(+), 16 deletions(-)

Otherwise, the patch looks good to me. Thanks.
Aryan Gupta March 7, 2024, 2:23 p.m. UTC | #2
On Thu, Mar 7, 2024 at 2:28 PM Christian Couder
<christian.couder@gmail.com> wrote:
>
> On Wed, Mar 6, 2024 at 10:46 AM Aryan Gupta via GitGitGadget
> <gitgitgadget@gmail.com> wrote:
> >
> > From: Aryan Gupta <garyan447@gmail.com>
> >
> > Modernize the formatting of the test script to align with current
> > standards and improve its overall readability.
> >
> > Signed-off-by: Aryan Gupta <garyan447@gmail.com>
> > ---
> >     [GSOC][PATCH] Modernize a test script
> >
> > Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1675%2Faryangupta701%2Ftest-modernize-v4
> > Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1675/aryangupta701/test-modernize-v4
> > Pull-Request: https://github.com/gitgitgadget/git/pull/1675
> >
> > Range-diff vs v3:
> >
> >  1:  05ee9e8a458 = 1:  14c7137baea tests: modernize the test script t0010-racy-git.sh
>
> This tells us that nothing changed in the patch since v3, so we can
> only wonder why you sent this v4.
>
> Did you fix some headers? Please explain.
>
Hey. Sorry for making a lot of mistakes in my emails.

I thought that there were some bugs in GGG due to which it sent some
headers which were not syntactically correct. So I tried sending it again.
And that was the whole purpose of this.

> >  t/t0010-racy-git.sh | 31 +++++++++++++++----------------
> >  1 file changed, 15 insertions(+), 16 deletions(-)
>
> Otherwise, the patch looks good to me. Thanks.
Junio C Hamano March 7, 2024, 6:17 p.m. UTC | #3
Aryan Gupta <garyan447@gmail.com> writes:

> I thought that there were some bugs in GGG due to which it sent some
> headers which were not syntactically correct. So I tried sending it again.
> And that was the whole purpose of this.

I was wondering about the same thing.  I still see an unwanted "[ ]"
around Kristoffer's e-mail address that will break responding to the
message in your [PATCH v4] e-mail that can be seen at

  https://lore.kernel.org/git/pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com/raw

so, the experiment revealed that it did send some headers were
broken.

Thanks for a clarification.
Junio C Hamano March 7, 2024, 6:30 p.m. UTC | #4
Junio C Hamano <gitster@pobox.com> writes:

> I was wondering about the same thing.  I still see an unwanted "[ ]"
> around Kristoffer's e-mail address that will break responding to the
> message in your [PATCH v4] e-mail that can be seen at
>
>   https://lore.kernel.org/git/pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com/raw
>
> so, the experiment revealed that it did send some headers were
> broken.

This does not necessarily mean GGG is broken.  The majority of the
patches I see here from GGG are without these funny [square-bracket]
around addresses at all, and this was the only patch (or it is
possible that your other patches may have had the same issue; I do
not remember) with that problem.  It might be caused by what you
feed GGG (e.g., the messages you give it in your pull request) that
caused GGG to hiccup, perhaps?
Aryan Gupta March 7, 2024, 6:33 p.m. UTC | #5
On Thu, Mar 7, 2024 at 7:30 PM Junio C Hamano <gitster@pobox.com> wrote:
>
> Junio C Hamano <gitster@pobox.com> writes:
>
> > I was wondering about the same thing.  I still see an unwanted "[ ]"
> > around Kristoffer's e-mail address that will break responding to the
> > message in your [PATCH v4] e-mail that can be seen at
> >
> >   https://lore.kernel.org/git/pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com/raw
> >
> > so, the experiment revealed that it did send some headers were
> > broken.
>
> This does not necessarily mean GGG is broken.  The majority of the
> patches I see here from GGG are without these funny [square-bracket]
> around addresses at all, and this was the only patch (or it is
> possible that your other patches may have had the same issue; I do
> not remember) with that problem.  It might be caused by what you
> feed GGG (e.g., the messages you give it in your pull request) that
> caused GGG to hiccup, perhaps?
>
Ohh yes. I think I got the problem. I have fixed it. Can I try sending
the patch again now?
diff mbox series

Patch

diff --git a/t/t0010-racy-git.sh b/t/t0010-racy-git.sh
index 837c8b7228b..84172a37390 100755
--- a/t/t0010-racy-git.sh
+++ b/t/t0010-racy-git.sh
@@ -10,25 +10,24 @@  TEST_PASSES_SANITIZE_LEAK=true
 
 for trial in 0 1 2 3 4
 do
-	rm -f .git/index
-	echo frotz >infocom
-	git update-index --add infocom
-	echo xyzzy >infocom
-
-	files=$(git diff-files -p)
-	test_expect_success \
-	"Racy GIT trial #$trial part A" \
-	'test "" != "$files"'
-
+	test_expect_success "Racy git trial #$trial part A" '
+		rm -f .git/index &&
+		echo frotz >infocom &&
+		git update-index --add infocom &&
+		echo xyzzy >infocom &&
+
+		git diff-files -p >out &&
+		test_file_not_empty out
+	'
 	sleep 1
-	echo xyzzy >cornerstone
-	git update-index --add cornerstone
 
-	files=$(git diff-files -p)
-	test_expect_success \
-	"Racy GIT trial #$trial part B" \
-	'test "" != "$files"'
+	test_expect_success "Racy git trial #$trial part B" '
+		echo xyzzy >cornerstone &&
+		git update-index --add cornerstone &&
 
+		git diff-files -p >out &&
+		test_file_not_empty out
+	'
 done
 
 test_done