@@ -52,21 +52,17 @@ get_static_files() {
52
52
SMART=smart
53
53
GIT_HTTP_EXPORT_ALL=1 && export GIT_HTTP_EXPORT_ALL
54
54
test_expect_success 'direct refs/heads/master not found' '
55
- log_div "refs/heads/master" &&
56
55
GET refs/heads/master "404 Not Found"
57
56
'
58
57
test_expect_success 'static file is ok' '
59
- log_div "getanyfile default" &&
60
58
get_static_files "200 OK"
61
59
'
62
60
SMART=smart_noexport
63
61
unset GIT_HTTP_EXPORT_ALL
64
62
test_expect_success 'no export by default' '
65
- log_div "no git-daemon-export-ok" &&
66
63
get_static_files "404 Not Found"
67
64
'
68
65
test_expect_success 'export if git-daemon-export-ok' '
69
- log_div "git-daemon-export-ok" &&
70
66
(cd "$HTTPD_DOCUMENT_ROOT_PATH/repo.git" &&
71
67
touch git-daemon-export-ok
72
68
) &&
@@ -75,47 +71,39 @@ test_expect_success 'export if git-daemon-export-ok' '
75
71
SMART=smart
76
72
GIT_HTTP_EXPORT_ALL=1 && export GIT_HTTP_EXPORT_ALL
77
73
test_expect_success 'static file if http.getanyfile true is ok' '
78
- log_div "getanyfile true" &&
79
74
config http.getanyfile true &&
80
75
get_static_files "200 OK"
81
76
'
82
77
test_expect_success 'static file if http.getanyfile false fails' '
83
- log_div "getanyfile false" &&
84
78
config http.getanyfile false &&
85
79
get_static_files "403 Forbidden"
86
80
'
87
81
88
82
test_expect_success 'http.uploadpack default enabled' '
89
- log_div "uploadpack default" &&
90
83
GET info/refs?service=git-upload-pack "200 OK" &&
91
84
POST git-upload-pack 0000 "200 OK"
92
85
'
93
86
test_expect_success 'http.uploadpack true' '
94
- log_div "uploadpack true" &&
95
87
config http.uploadpack true &&
96
88
GET info/refs?service=git-upload-pack "200 OK" &&
97
89
POST git-upload-pack 0000 "200 OK"
98
90
'
99
91
test_expect_success 'http.uploadpack false' '
100
- log_div "uploadpack false" &&
101
92
config http.uploadpack false &&
102
93
GET info/refs?service=git-upload-pack "403 Forbidden" &&
103
94
POST git-upload-pack 0000 "403 Forbidden"
104
95
'
105
96
106
97
test_expect_success 'http.receivepack default disabled' '
107
- log_div "receivepack default" &&
108
98
GET info/refs?service=git-receive-pack "403 Forbidden" &&
109
99
POST git-receive-pack 0000 "403 Forbidden"
110
100
'
111
101
test_expect_success 'http.receivepack true' '
112
- log_div "receivepack true" &&
113
102
config http.receivepack true &&
114
103
GET info/refs?service=git-receive-pack "200 OK" &&
115
104
POST git-receive-pack 0000 "200 OK"
116
105
'
117
106
test_expect_success 'http.receivepack false' '
118
- log_div "receivepack false" &&
119
107
config http.receivepack false &&
120
108
GET info/refs?service=git-receive-pack "403 Forbidden" &&
121
109
POST git-receive-pack 0000 "403 Forbidden"
0 commit comments