summaryrefslogtreecommitdiff
path: root/t/t5540-http-push.sh
diff options
context:
space:
mode:
authorTay Ray Chuan <rctay89@gmail.com>2009-06-06 08:43:27 (GMT)
committerJunio C Hamano <gitster@pobox.com>2009-06-06 17:56:27 (GMT)
commit4f66250df641362f381faae2aec439850a5a6e41 (patch)
tree81619c14cda8b1c5519f6a4fd3dabd7b98ff383a /t/t5540-http-push.sh
parent86d99f6d5ce1120b23a2453168165ac45e039411 (diff)
downloadgit-4f66250df641362f381faae2aec439850a5a6e41.zip
git-4f66250df641362f381faae2aec439850a5a6e41.tar.gz
git-4f66250df641362f381faae2aec439850a5a6e41.tar.bz2
http-push: send out fetch requests on queue
Previously, requests for remote files were simply added to the queue (pointed to by request_queue_head) and no transfer actually takes place (the fill function add_fill_function() is not added until line 2441), even though code that followed may rely on these remote files to be present (eg. the setup_revisions invocation). The code that sends out the requests on the request queue is refactored into the method run_request_queue. After the get_dav_remote_heads invocation (ie. after fetch requests are added to the queue), the requests on the queue are sent out through an invocation to run_request_queue. This invocation to run_request_queue entails adding a fill function before pushing checks take place, which may lead to accidental, unwanted pushes previously. The flag is_running_queue is introduced to prevent this from occurring. fill_active_slot is made to check the flag is_running_queue before the sending of the requests proceeds. Signed-off-by: Tay Ray Chuan <rctay89@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5540-http-push.sh')
-rwxr-xr-xt/t5540-http-push.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/t/t5540-http-push.sh b/t/t5540-http-push.sh
index ad0f14b..f4a2cf6 100755
--- a/t/t5540-http-push.sh
+++ b/t/t5540-http-push.sh
@@ -67,7 +67,7 @@ test_expect_success ' push to remote repository with unpacked refs' '
test $HEAD = $(git rev-parse --verify HEAD))
'
-test_expect_failure 'http-push fetches unpacked objects' '
+test_expect_success 'http-push fetches unpacked objects' '
cp -R "$HTTPD_DOCUMENT_ROOT_PATH"/test_repo.git \
"$HTTPD_DOCUMENT_ROOT_PATH"/test_repo_unpacked.git &&
@@ -83,7 +83,7 @@ test_expect_failure 'http-push fetches unpacked objects' '
git push -f -v $HTTPD_URL/test_repo_unpacked.git master)
'
-test_expect_failure 'http-push fetches packed objects' '
+test_expect_success 'http-push fetches packed objects' '
cp -R "$HTTPD_DOCUMENT_ROOT_PATH"/test_repo.git \
"$HTTPD_DOCUMENT_ROOT_PATH"/test_repo_packed.git &&