Re: [PATCH v4 23/28] Support shallow fetch/clone over smart-http
- From
Jeff King <peff@peff.net>
- Date
- Jan 8, 2014, 11:25 UTC
- Message-ID
- <20140108112543.GA4419@sigill.intra.peff.net>
- In-Reply-To
- <1386248575-10206-24-git-send-email-pclouds@gmail.com>
On Thu, Dec 05, 2013 at 08:02:50PM +0700, Nguyễn Thái Ngọc Duy wrote:
Show 6 quoted lines
> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> > --- > Documentation/gitremote-helpers.txt | 7 +++++++ > builtin/fetch-pack.c | 16 +++++++++++++--- > remote-curl.c | 31 +++++++++++++++++++++++++++++-- > t/t5536-fetch-shallow.sh | 27 +++++++++++++++++++++++++++
I'm getting test failures in 'next' with GIT_TEST_HTTPD set, and they are bisectable to this patch (actually, the moral equivalent of it, as it looks like the commit message was tweaked along with the test number when it was applied). The failures look like this:
$ GIT_TEST_HTTPD=1 ./t5537-fetch-shallow.sh -v -i
[...]
ok 9 - fetch --update-shallow
expecting success:
git clone --bare --no-local shallow "$HTTPD_DOCUMENT_ROOT_PATH/repo.git" &&
git clone $HTTPD_URL/smart/repo.git clone &&
(
cd clone &&
git fsck &&
git log --format=%s origin/master >actual &&
cat <<EOF >expect &&
6
5
4
3
EOF
test_cmp expect actual
)
Cloning into bare repository '/home/peff/compile/git/t/trash directory.t5537-fetch-shallow/httpd/www/repo.git'...
remote: Counting objects: 19, done.
remote: Compressing objects: 100% (7/7), done.
remote: Total 19 (delta 0), reused 6 (delta 0)
Receiving objects: 100% (19/19), done.
Checking connectivity... done.
Cloning into 'clone'...
remote: Counting objects: 19, done.
remote: Compressing objects: 100% (7/7), done.
remote: Total 19 (delta 0), reused 19 (delta 0)
Unpacking objects: 100% (19/19), done.
Checking connectivity... done.
Checking object directories: 100% (256/256), done.
--- expect 2014-01-08 11:20:20.178546452 +0000
+++ actual 2014-01-08 11:20:20.178546452 +0000
@@ -1,3 +1,4 @@
+7
6
5
4
not ok 10 - clone http repositoryIf you do end up tweaking the test, you may also want to fix:
> +LIB_HTTPD_PORT=${LIB_HTTPD_PORT-'5536'}
> +. "$TEST_DIRECTORY"/lib-httpd.shSince the test number got switched, it would be nice to tweak the port number to match it, in case the real t5536 ever starts using lib-httpd.
-Peff