File tree Expand file tree Collapse file tree 1 file changed +28
-1
lines changed Expand file tree Collapse file tree 1 file changed +28
-1
lines changed Original file line number Diff line number Diff line change @@ -34,8 +34,34 @@ test_expect_success 'setup remote repository' '
34
34
mv test_repo.git "$HTTPD_DOCUMENT_ROOT_PATH"
35
35
'
36
36
37
- test_expect_success ' clone remote repository' '
37
+ cat > exp << EOF
38
+ GET /smart/test_repo.git/info/refs?service=git-upload-pack HTTP/1.1 200
39
+ POST /smart/test_repo.git/git-upload-pack HTTP/1.1 200
40
+ EOF
41
+ test_expect_failure ' no empty path components' '
42
+ # In the URL, add a trailing slash, and see if git appends yet another
43
+ # slash.
38
44
cd "$ROOT_PATH" &&
45
+ git clone $HTTPD_URL/smart/test_repo.git/ test_repo_clone &&
46
+
47
+ sed -e "
48
+ s/^.* \"//
49
+ s/\"//
50
+ s/ [1-9][0-9]*\$//
51
+ s/^GET /GET /
52
+ " >act <"$HTTPD_ROOT_PATH"/access.log &&
53
+
54
+ # Clear the log, so that it does not affect the "used receive-pack
55
+ # service" test which reads the log too.
56
+ #
57
+ # We do this before the actual comparison to ensure the log is cleared.
58
+ echo > "$HTTPD_ROOT_PATH"/access.log &&
59
+
60
+ test_cmp exp act
61
+ '
62
+
63
+ test_expect_success ' clone remote repository' '
64
+ rm -rf test_repo_clone &&
39
65
git clone $HTTPD_URL/smart/test_repo.git test_repo_clone
40
66
'
41
67
@@ -68,6 +94,7 @@ test_expect_success 'create and delete remote branch' '
68
94
'
69
95
70
96
cat > exp << EOF
97
+
71
98
GET /smart/test_repo.git/info/refs?service=git-upload-pack HTTP/1.1 200
72
99
POST /smart/test_repo.git/git-upload-pack HTTP/1.1 200
73
100
GET /smart/test_repo.git/info/refs?service=git-receive-pack HTTP/1.1 200
You can’t perform that action at this time.
0 commit comments