* [PATCH 0/4] test suite: use the GIT_TRACE_CURL environment var
@ 2016-09-05 10:24 Elia Pinto
2016-09-05 10:24 ` [PATCH 1/4] t5541-http-push-smart.sh: " Elia Pinto
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: Elia Pinto @ 2016-09-05 10:24 UTC (permalink / raw)
To: git; +Cc: Elia Pinto
Use the new GIT_TRACE_CURL environment variable in the test suite
instead of the deprecated GIT_CURL_VERBOSE.
Elia Pinto (4):
t5541-http-push-smart.sh: use the GIT_TRACE_CURL environment var
test-lib.sh: preserve GIT_TRACE_CURL from the environment
t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var
t5551-http-fetch-smart.sh: use the GIT_TRACE_CURL environment var
t/t5541-http-push-smart.sh | 2 +-
t/t5550-http-fetch-dumb.sh | 13 ++++++++-----
t/t5551-http-fetch-smart.sh | 15 ++++++++++++---
t/test-lib.sh | 1 +
4 files changed, 22 insertions(+), 9 deletions(-)
--
2.10.0.308.gf73994d
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH 1/4] t5541-http-push-smart.sh: use the GIT_TRACE_CURL environment var
2016-09-05 10:24 [PATCH 0/4] test suite: use the GIT_TRACE_CURL environment var Elia Pinto
@ 2016-09-05 10:24 ` Elia Pinto
2016-09-05 10:24 ` [PATCH 2/4] test-lib.sh: preserve GIT_TRACE_CURL from the environment Elia Pinto
` (2 subsequent siblings)
3 siblings, 0 replies; 9+ messages in thread
From: Elia Pinto @ 2016-09-05 10:24 UTC (permalink / raw)
To: git; +Cc: Elia Pinto
Use the new GIT_TRACE_CURL environment variable instead
of the deprecated GIT_CURL_VERBOSE.
Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>
---
t/t5541-http-push-smart.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/t/t5541-http-push-smart.sh b/t/t5541-http-push-smart.sh
index 4840c71..d38bf32 100755
--- a/t/t5541-http-push-smart.sh
+++ b/t/t5541-http-push-smart.sh
@@ -74,7 +74,7 @@ test_expect_success 'push to remote repository (standard)' '
test_tick &&
git commit -m path2 &&
HEAD=$(git rev-parse --verify HEAD) &&
- GIT_CURL_VERBOSE=1 git push -v -v 2>err &&
+ GIT_TRACE_CURL=true git push -v -v 2>err &&
! grep "Expect: 100-continue" err &&
grep "POST git-receive-pack ([0-9]* bytes)" err &&
(cd "$HTTPD_DOCUMENT_ROOT_PATH"/test_repo.git &&
--
2.10.0.308.gf73994d
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 2/4] test-lib.sh: preserve GIT_TRACE_CURL from the environment
2016-09-05 10:24 [PATCH 0/4] test suite: use the GIT_TRACE_CURL environment var Elia Pinto
2016-09-05 10:24 ` [PATCH 1/4] t5541-http-push-smart.sh: " Elia Pinto
@ 2016-09-05 10:24 ` Elia Pinto
2016-09-05 10:24 ` [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var Elia Pinto
2016-09-05 10:24 ` [PATCH 4/4] t5551-http-fetch-smart.sh: " Elia Pinto
3 siblings, 0 replies; 9+ messages in thread
From: Elia Pinto @ 2016-09-05 10:24 UTC (permalink / raw)
To: git; +Cc: Elia Pinto
Turning on this variable can be useful when debugging http
tests. It can break a few tests in t5541 if not set
to an absolute path but it is not a variable
that the user is likely to have enabled accidentally.
Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>
---
t/test-lib.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/t/test-lib.sh b/t/test-lib.sh
index d731d66..986eba1 100644
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -89,6 +89,7 @@ unset VISUAL EMAIL LANGUAGE COLUMNS $("$PERL_PATH" -e '
UNZIP
PERF_
CURL_VERBOSE
+ TRACE_CURL
));
my @vars = grep(/^GIT_/ && !/^GIT_($ok)/o, @env);
print join("\n", @vars);
--
2.10.0.308.gf73994d
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var
2016-09-05 10:24 [PATCH 0/4] test suite: use the GIT_TRACE_CURL environment var Elia Pinto
2016-09-05 10:24 ` [PATCH 1/4] t5541-http-push-smart.sh: " Elia Pinto
2016-09-05 10:24 ` [PATCH 2/4] test-lib.sh: preserve GIT_TRACE_CURL from the environment Elia Pinto
@ 2016-09-05 10:24 ` Elia Pinto
2016-09-05 13:43 ` Eric Sunshine
2016-09-05 10:24 ` [PATCH 4/4] t5551-http-fetch-smart.sh: " Elia Pinto
3 siblings, 1 reply; 9+ messages in thread
From: Elia Pinto @ 2016-09-05 10:24 UTC (permalink / raw)
To: git; +Cc: Elia Pinto
Use the new GIT_TRACE_CURL environment variable instead
of the deprecated GIT_CURL_VERBOSE.
Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>
---
t/t5550-http-fetch-dumb.sh | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/t/t5550-http-fetch-dumb.sh b/t/t5550-http-fetch-dumb.sh
index 3484b6f..75694ad 100755
--- a/t/t5550-http-fetch-dumb.sh
+++ b/t/t5550-http-fetch-dumb.sh
@@ -263,15 +263,18 @@ check_language () {
>expect
;;
?*)
- echo "Accept-Language: $1" >expect
+ echo "=> Send header: Accept-Language: $1" >expect
;;
esac &&
- GIT_CURL_VERBOSE=1 \
+ GIT_TRACE_CURL=true \
LANGUAGE=$2 \
git ls-remote "$HTTPD_URL/dumb/repo.git" >output 2>&1 &&
tr -d '\015' <output |
sort -u |
- sed -ne '/^Accept-Language:/ p' >actual &&
+ sed -ne '/^=> Send header: Accept-Language:/ p' >actual &&
+ cp expect expect.$$ &&
+ cp actual actual.$$ &&
+ cp output output.$$ &&
test_cmp expect actual
}
@@ -295,8 +298,8 @@ ja;q=0.95, zh;q=0.94, sv;q=0.93, pt;q=0.92, nb;q=0.91, *;q=0.90" \
'
test_expect_success 'git client does not send an empty Accept-Language' '
- GIT_CURL_VERBOSE=1 LANGUAGE= git ls-remote "$HTTPD_URL/dumb/repo.git" 2>stderr &&
- ! grep "^Accept-Language:" stderr
+ GIT_TRACE_CURL=true LANGUAGE= git ls-remote "$HTTPD_URL/dumb/repo.git" 2>stderr &&
+ ! grep "^=> Send header: Accept-Language:" stderr
'
stop_httpd
--
2.10.0.308.gf73994d
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH 4/4] t5551-http-fetch-smart.sh: use the GIT_TRACE_CURL environment var
2016-09-05 10:24 [PATCH 0/4] test suite: use the GIT_TRACE_CURL environment var Elia Pinto
` (2 preceding siblings ...)
2016-09-05 10:24 ` [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var Elia Pinto
@ 2016-09-05 10:24 ` Elia Pinto
3 siblings, 0 replies; 9+ messages in thread
From: Elia Pinto @ 2016-09-05 10:24 UTC (permalink / raw)
To: git; +Cc: Elia Pinto
Use the new GIT_TRACE_CURL environment variable instead
of the deprecated GIT_CURL_VERBOSE.
Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>
---
t/t5551-http-fetch-smart.sh | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/t/t5551-http-fetch-smart.sh b/t/t5551-http-fetch-smart.sh
index 2f375eb..1ec5b27 100755
--- a/t/t5551-http-fetch-smart.sh
+++ b/t/t5551-http-fetch-smart.sh
@@ -43,12 +43,21 @@ cat >exp <<EOF
< Content-Type: application/x-git-upload-pack-result
EOF
test_expect_success 'clone http repository' '
- GIT_CURL_VERBOSE=1 git clone --quiet $HTTPD_URL/smart/repo.git clone 2>err &&
+ GIT_TRACE_CURL=true git clone --quiet $HTTPD_URL/smart/repo.git clone 2>err &&
test_cmp file clone/file &&
tr '\''\015'\'' Q <err |
sed -e "
s/Q\$//
/^[*] /d
+ /^== Info:/d
+ /^=> Send header, /d
+ /^=> Send header:$/d
+ /^<= Recv header, /d
+ /^<= Recv header:$/d
+ s/=> Send header: //
+ s/= Recv header://
+ /^<= Recv data/d
+ /^=> Send data/d
/^$/d
/^< $/d
@@ -261,9 +270,9 @@ test_expect_success CMDLINE_LIMIT \
'
test_expect_success 'large fetch-pack requests can be split across POSTs' '
- GIT_CURL_VERBOSE=1 git -c http.postbuffer=65536 \
+ GIT_TRACE_CURL=true git -c http.postbuffer=65536 \
clone --bare "$HTTPD_URL/smart/repo.git" split.git 2>err &&
- grep "^> POST" err >posts &&
+ grep "^=> Send header: POST" err >posts &&
test_line_count = 2 posts
'
--
2.10.0.308.gf73994d
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var
2016-09-05 10:24 ` [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var Elia Pinto
@ 2016-09-05 13:43 ` Eric Sunshine
2016-09-05 19:09 ` Elia Pinto
0 siblings, 1 reply; 9+ messages in thread
From: Eric Sunshine @ 2016-09-05 13:43 UTC (permalink / raw)
To: Elia Pinto; +Cc: Git List
On Mon, Sep 5, 2016 at 6:24 AM, Elia Pinto <gitter.spiros@gmail.com> wrote:
> Use the new GIT_TRACE_CURL environment variable instead
> of the deprecated GIT_CURL_VERBOSE.
>
> Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>
> ---
> diff --git a/t/t5550-http-fetch-dumb.sh b/t/t5550-http-fetch-dumb.sh
> @@ -263,15 +263,18 @@ check_language () {
> >expect
> ;;
> ?*)
> - echo "Accept-Language: $1" >expect
> + echo "=> Send header: Accept-Language: $1" >expect
> ;;
> esac &&
> - GIT_CURL_VERBOSE=1 \
> + GIT_TRACE_CURL=true \
> LANGUAGE=$2 \
> git ls-remote "$HTTPD_URL/dumb/repo.git" >output 2>&1 &&
> tr -d '\015' <output |
> sort -u |
> - sed -ne '/^Accept-Language:/ p' >actual &&
> + sed -ne '/^=> Send header: Accept-Language:/ p' >actual &&
> + cp expect expect.$$ &&
> + cp actual actual.$$ &&
> + cp output output.$$ &&
What are these three cp's about? They don't seem to be related to the
stated changes. Are they leftover debugging gunk?
> test_cmp expect actual
> }
>
> @@ -295,8 +298,8 @@ ja;q=0.95, zh;q=0.94, sv;q=0.93, pt;q=0.92, nb;q=0.91, *;q=0.90" \
> '
>
> test_expect_success 'git client does not send an empty Accept-Language' '
> - GIT_CURL_VERBOSE=1 LANGUAGE= git ls-remote "$HTTPD_URL/dumb/repo.git" 2>stderr &&
> - ! grep "^Accept-Language:" stderr
> + GIT_TRACE_CURL=true LANGUAGE= git ls-remote "$HTTPD_URL/dumb/repo.git" 2>stderr &&
> + ! grep "^=> Send header: Accept-Language:" stderr
> '
>
> stop_httpd
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var
2016-09-05 13:43 ` Eric Sunshine
@ 2016-09-05 19:09 ` Elia Pinto
2016-09-07 18:25 ` Junio C Hamano
0 siblings, 1 reply; 9+ messages in thread
From: Elia Pinto @ 2016-09-05 19:09 UTC (permalink / raw)
To: Eric Sunshine; +Cc: Git List
2016-09-05 15:43 GMT+02:00 Eric Sunshine <sunshine@sunshineco.com>:
> On Mon, Sep 5, 2016 at 6:24 AM, Elia Pinto <gitter.spiros@gmail.com> wrote:
>> Use the new GIT_TRACE_CURL environment variable instead
>> of the deprecated GIT_CURL_VERBOSE.
>>
>> Signed-off-by: Elia Pinto <gitter.spiros@gmail.com>
>> ---
>> diff --git a/t/t5550-http-fetch-dumb.sh b/t/t5550-http-fetch-dumb.sh
>> @@ -263,15 +263,18 @@ check_language () {
>> >expect
>> ;;
>> ?*)
>> - echo "Accept-Language: $1" >expect
>> + echo "=> Send header: Accept-Language: $1" >expect
>> ;;
>> esac &&
>> - GIT_CURL_VERBOSE=1 \
>> + GIT_TRACE_CURL=true \
>> LANGUAGE=$2 \
>> git ls-remote "$HTTPD_URL/dumb/repo.git" >output 2>&1 &&
>> tr -d '\015' <output |
>> sort -u |
>> - sed -ne '/^Accept-Language:/ p' >actual &&
>> + sed -ne '/^=> Send header: Accept-Language:/ p' >actual &&
>> + cp expect expect.$$ &&
>> + cp actual actual.$$ &&
>> + cp output output.$$ &&
>
> What are these three cp's about? They don't seem to be related to the
> stated changes. Are they leftover debugging gunk?
Yes, i am very sorry. My bad. I will repost. Thanks
>
>> test_cmp expect actual
>> }
>>
>> @@ -295,8 +298,8 @@ ja;q=0.95, zh;q=0.94, sv;q=0.93, pt;q=0.92, nb;q=0.91, *;q=0.90" \
>> '
>>
>> test_expect_success 'git client does not send an empty Accept-Language' '
>> - GIT_CURL_VERBOSE=1 LANGUAGE= git ls-remote "$HTTPD_URL/dumb/repo.git" 2>stderr &&
>> - ! grep "^Accept-Language:" stderr
>> + GIT_TRACE_CURL=true LANGUAGE= git ls-remote "$HTTPD_URL/dumb/repo.git" 2>stderr &&
>> + ! grep "^=> Send header: Accept-Language:" stderr
>> '
>>
>> stop_httpd
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var
2016-09-05 19:09 ` Elia Pinto
@ 2016-09-07 18:25 ` Junio C Hamano
2016-09-07 19:58 ` Junio C Hamano
0 siblings, 1 reply; 9+ messages in thread
From: Junio C Hamano @ 2016-09-07 18:25 UTC (permalink / raw)
To: Elia Pinto; +Cc: Eric Sunshine, Git List
Elia Pinto <gitter.spiros@gmail.com> writes:
>>> + cp expect expect.$$ &&
>>> + cp actual actual.$$ &&
>>> + cp output output.$$ &&
>>
>> What are these three cp's about? They don't seem to be related to the
>> stated changes. Are they leftover debugging gunk?
> Yes, i am very sorry. My bad. I will repost. Thanks
Nevertheless, thanks for these clean-ups. Will discard this round
waiting for a reroll.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var
2016-09-07 18:25 ` Junio C Hamano
@ 2016-09-07 19:58 ` Junio C Hamano
0 siblings, 0 replies; 9+ messages in thread
From: Junio C Hamano @ 2016-09-07 19:58 UTC (permalink / raw)
To: Elia Pinto; +Cc: Eric Sunshine, Git List
Junio C Hamano <gitster@pobox.com> writes:
> Elia Pinto <gitter.spiros@gmail.com> writes:
>
>>>> + cp expect expect.$$ &&
>>>> + cp actual actual.$$ &&
>>>> + cp output output.$$ &&
>>>
>>> What are these three cp's about? They don't seem to be related to the
>>> stated changes. Are they leftover debugging gunk?
>> Yes, i am very sorry. My bad. I will repost. Thanks
>
> Nevertheless, thanks for these clean-ups. Will discard this round
> waiting for a reroll.
Nevermind. I see you rerolled only this one labeled as "v1 3/4";
picked up the rest from this series and combined with that reroll.
Thanks.
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2016-09-07 19:59 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-05 10:24 [PATCH 0/4] test suite: use the GIT_TRACE_CURL environment var Elia Pinto
2016-09-05 10:24 ` [PATCH 1/4] t5541-http-push-smart.sh: " Elia Pinto
2016-09-05 10:24 ` [PATCH 2/4] test-lib.sh: preserve GIT_TRACE_CURL from the environment Elia Pinto
2016-09-05 10:24 ` [PATCH 3/4] t5550-http-fetch-dumb.sh: use the GIT_TRACE_CURL environment var Elia Pinto
2016-09-05 13:43 ` Eric Sunshine
2016-09-05 19:09 ` Elia Pinto
2016-09-07 18:25 ` Junio C Hamano
2016-09-07 19:58 ` Junio C Hamano
2016-09-05 10:24 ` [PATCH 4/4] t5551-http-fetch-smart.sh: " Elia Pinto
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.