]> git.ipfire.org Git - thirdparty/git.git/blob - t/t0611-reftable-httpd.sh
The second batch
[thirdparty/git.git] / t / t0611-reftable-httpd.sh
1 #!/bin/sh
2
3 test_description='reftable HTTPD tests'
4
5 . ./test-lib.sh
6 . "$TEST_DIRECTORY"/lib-httpd.sh
7
8 start_httpd
9
10 REPO="$HTTPD_DOCUMENT_ROOT_PATH/repo"
11
12 test_expect_success 'serving ls-remote' '
13 git init --ref-format=reftable -b main "$REPO" &&
14 cd "$REPO" &&
15 test_commit m1 &&
16 >.git/git-daemon-export-ok &&
17 git ls-remote "http://127.0.0.1:$LIB_HTTPD_PORT/smart/repo" | cut -f 2-2 -d " " >actual &&
18 cat >expect <<-EOF &&
19 HEAD
20 refs/heads/main
21 refs/tags/m1
22 EOF
23 test_cmp actual expect
24 '
25
26 test_done