t5411: start adjusting the support files for init.defaultBranch=main
This trick was performed via $ sed -i -e 's/master/main/g' -e 's/MASTER/MAIN/g' \ -e 's/Master/Main/g' -- t/t5411/test-00[3-5]* We do not convert the files in `t/t5411/` in one go because the patch would be too big (mails larger than 100kB are rejected by the Git mailing list). Instead, we start with roughly half of the support files. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Johannes Schindelin committed
Oct 31, 2020 at 19:46 UTC
8f0a264524d72c6a083b0debcbb1d795a9f4f090
13 files changed
+361
-361
t/t5411/test-0030-report-ok.sh
+11
-11
@@ -2,34 +2,34 @@ test_expect_success "setup proc-receive hook (ok, $PROTOCOL)" '
2
write_script "$upstream/hooks/proc-receive" <<-EOF
3
printf >&2 "# proc-receive hook\n"
4
test-tool proc-receive -v \
5
- -r "ok refs/for/master/topic"
5
+ -r "ok refs/for/main/topic"
6
EOF
7
'
8
9
-# Refs of upstream : master(A)
10
-# Refs of workbench: master(A) tags/v123
11
-# git push : refs/for/master/topic
9
+# Refs of upstream : main(A)
10
+# Refs of workbench: main(A) tags/v123
11
+# git push : refs/for/main/topic
12
test_expect_success "proc-receive: ok ($PROTOCOL)" '
13
git -C workbench push origin \
14
- HEAD:refs/for/master/topic \
14
+ HEAD:refs/for/main/topic \
15
>out 2>&1 &&
16
make_user_friendly_and_stable_output <out >actual &&
17
cat >expect <<-EOF &&
18
remote: # pre-receive hook
19
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
19
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
20
remote: # proc-receive hook
21
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
22
- remote: proc-receive> ok refs/for/master/topic
21
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
22
+ remote: proc-receive> ok refs/for/main/topic
23
remote: # post-receive hook
24
- remote: post-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
24
+ remote: post-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
25
To <URL/of/upstream.git>
26
- * [new reference] HEAD -> refs/for/master/topic
26
+ * [new reference] HEAD -> refs/for/main/topic
27
EOF
28
test_cmp expect actual &&
29
git -C "$upstream" show-ref >out &&
30
make_user_friendly_and_stable_output <out >actual &&
31
cat >expect <<-EOF &&
32
- <COMMIT-A> refs/heads/master
32
+ <COMMIT-A> refs/heads/main
33
EOF
34
test_cmp expect actual
35
'
t/t5411/test-0031-report-ok--porcelain.sh
+11
-11
@@ -2,35 +2,35 @@ test_expect_success "setup proc-receive hook (ok, $PROTOCOL/porcelain)" '
2
write_script "$upstream/hooks/proc-receive" <<-EOF
3
printf >&2 "# proc-receive hook\n"
4
test-tool proc-receive -v \
5
- -r "ok refs/for/master/topic"
5
+ -r "ok refs/for/main/topic"
6
EOF
7
'
8
9
-# Refs of upstream : master(A)
10
-# Refs of workbench: master(A) tags/v123
11
-# git push : refs/for/master/topic
9
+# Refs of upstream : main(A)
10
+# Refs of workbench: main(A) tags/v123
11
+# git push : refs/for/main/topic
12
test_expect_success "proc-receive: ok ($PROTOCOL/porcelain)" '
13
git -C workbench push --porcelain origin \
14
- HEAD:refs/for/master/topic \
14
+ HEAD:refs/for/main/topic \
15
>out 2>&1 &&
16
make_user_friendly_and_stable_output <out >actual &&
17
cat >expect <<-EOF &&
18
remote: # pre-receive hook
19
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
19
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
20
remote: # proc-receive hook
21
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
22
- remote: proc-receive> ok refs/for/master/topic
21
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
22
+ remote: proc-receive> ok refs/for/main/topic
23
remote: # post-receive hook
24
- remote: post-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
24
+ remote: post-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
25
To <URL/of/upstream.git>
26
- * HEAD:refs/for/master/topic [new reference]
26
+ * HEAD:refs/for/main/topic [new reference]
27
Done
28
EOF
29
test_cmp expect actual &&
30
git -C "$upstream" show-ref >out &&
31
make_user_friendly_and_stable_output <out >actual &&
32
cat >expect <<-EOF &&
33
- <COMMIT-A> refs/heads/master
33
+ <COMMIT-A> refs/heads/main
34
EOF
35
test_cmp expect actual
36
'
t/t5411/test-0032-report-with-options.sh
+60
-60
@@ -7,24 +7,24 @@ test_expect_success "setup proc-receive hook (option without matching ok, $PROTO
7
EOF
8
'
9
10
-# Refs of upstream : master(A)
11
-# Refs of workbench: master(A) tags/v123
12
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
10
+# Refs of upstream : main(A)
11
+# Refs of workbench: main(A) tags/v123
12
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
13
test_expect_success "proc-receive: report option without matching ok ($PROTOCOL)" '
14
test_must_fail git -C workbench push origin \
15
- HEAD:refs/for/master/topic \
15
+ HEAD:refs/for/main/topic \
16
>out 2>&1 &&
17
make_user_friendly_and_stable_output <out >actual &&
18
cat >expect <<-EOF &&
19
remote: # pre-receive hook
20
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
20
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
21
remote: # proc-receive hook
22
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
22
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
23
remote: proc-receive> option refname refs/pull/123/head
24
remote: proc-receive> option old-oid <COMMIT-B>
25
remote: error: proc-receive reported "option" without a matching "ok/ng" directive
26
To <URL/of/upstream.git>
27
- ! [remote rejected] HEAD -> refs/for/master/topic (proc-receive failed to report status)
27
+ ! [remote rejected] HEAD -> refs/for/main/topic (proc-receive failed to report status)
28
EOF
29
test_cmp expect actual
30
'
@@ -33,25 +33,25 @@ test_expect_success "setup proc-receive hook (option refname, $PROTOCOL)" '
33
write_script "$upstream/hooks/proc-receive" <<-EOF
34
printf >&2 "# proc-receive hook\n"
35
test-tool proc-receive -v \
36
- -r "ok refs/for/master/topic" \
36
+ -r "ok refs/for/main/topic" \
37
-r "option refname refs/pull/123/head"
38
EOF
39
'
40
41
-# Refs of upstream : master(A)
42
-# Refs of workbench: master(A) tags/v123
43
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
41
+# Refs of upstream : main(A)
42
+# Refs of workbench: main(A) tags/v123
43
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
44
test_expect_success "proc-receive: report option refname ($PROTOCOL)" '
45
git -C workbench push origin \
46
- HEAD:refs/for/master/topic \
46
+ HEAD:refs/for/main/topic \
47
>out 2>&1 &&
48
make_user_friendly_and_stable_output <out >actual &&
49
cat >expect <<-EOF &&
50
remote: # pre-receive hook
51
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
51
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
52
remote: # proc-receive hook
53
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
54
- remote: proc-receive> ok refs/for/master/topic
53
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
54
+ remote: proc-receive> ok refs/for/main/topic
55
remote: proc-receive> option refname refs/pull/123/head
56
remote: # post-receive hook
57
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/pull/123/head
@@ -65,25 +65,25 @@ test_expect_success "setup proc-receive hook (option refname and forced-update,
65
write_script "$upstream/hooks/proc-receive" <<-EOF
66
printf >&2 "# proc-receive hook\n"
67
test-tool proc-receive -v \
68
- -r "ok refs/for/master/topic" \
68
+ -r "ok refs/for/main/topic" \
69
-r "option refname refs/pull/123/head" \
70
-r "option forced-update"
71
EOF
72
'
73
-# Refs of upstream : master(A)
74
-# Refs of workbench: master(A) tags/v123
75
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
73
+# Refs of upstream : main(A)
74
+# Refs of workbench: main(A) tags/v123
75
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
76
test_expect_success "proc-receive: report option refname and forced-update ($PROTOCOL)" '
77
git -C workbench push origin \
78
- HEAD:refs/for/master/topic \
78
+ HEAD:refs/for/main/topic \
79
>out 2>&1 &&
80
make_user_friendly_and_stable_output <out >actual &&
81
cat >expect <<-EOF &&
82
remote: # pre-receive hook
83
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
83
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
84
remote: # proc-receive hook
85
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
86
- remote: proc-receive> ok refs/for/master/topic
85
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
86
+ remote: proc-receive> ok refs/for/main/topic
87
remote: proc-receive> option refname refs/pull/123/head
88
remote: proc-receive> option forced-update
89
remote: # post-receive hook
@@ -98,26 +98,26 @@ test_expect_success "setup proc-receive hook (option refname and old-oid, $PROTO
98
write_script "$upstream/hooks/proc-receive" <<-EOF
99
printf >&2 "# proc-receive hook\n"
100
test-tool proc-receive -v \
101
- -r "ok refs/for/master/topic" \
101
+ -r "ok refs/for/main/topic" \
102
-r "option refname refs/pull/123/head" \
103
-r "option old-oid $B"
104
EOF
105
'
106
107
-# Refs of upstream : master(A)
108
-# Refs of workbench: master(A) tags/v123
109
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
107
+# Refs of upstream : main(A)
108
+# Refs of workbench: main(A) tags/v123
109
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
110
test_expect_success "proc-receive: report option refname and old-oid ($PROTOCOL)" '
111
git -C workbench push origin \
112
- HEAD:refs/for/master/topic \
112
+ HEAD:refs/for/main/topic \
113
>out 2>&1 &&
114
make_user_friendly_and_stable_output <out >actual &&
115
cat >expect <<-EOF &&
116
remote: # pre-receive hook
117
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
117
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
118
remote: # proc-receive hook
119
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
120
- remote: proc-receive> ok refs/for/master/topic
119
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
120
+ remote: proc-receive> ok refs/for/main/topic
121
remote: proc-receive> option refname refs/pull/123/head
122
remote: proc-receive> option old-oid <COMMIT-B>
123
remote: # post-receive hook
@@ -132,30 +132,30 @@ test_expect_success "setup proc-receive hook (option old-oid, $PROTOCOL)" '
132
write_script "$upstream/hooks/proc-receive" <<-EOF
133
printf >&2 "# proc-receive hook\n"
134
test-tool proc-receive -v \
135
- -r "ok refs/for/master/topic" \
135
+ -r "ok refs/for/main/topic" \
136
-r "option old-oid $B"
137
EOF
138
'
139
140
-# Refs of upstream : master(A)
141
-# Refs of workbench: master(A) tags/v123
142
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
140
+# Refs of upstream : main(A)
141
+# Refs of workbench: main(A) tags/v123
142
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
143
test_expect_success "proc-receive: report option old-oid ($PROTOCOL)" '
144
git -C workbench push origin \
145
- HEAD:refs/for/master/topic \
145
+ HEAD:refs/for/main/topic \
146
>out 2>&1 &&
147
make_user_friendly_and_stable_output <out >actual &&
148
cat >expect <<-EOF &&
149
remote: # pre-receive hook
150
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
150
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
151
remote: # proc-receive hook
152
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
153
- remote: proc-receive> ok refs/for/master/topic
152
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
153
+ remote: proc-receive> ok refs/for/main/topic
154
remote: proc-receive> option old-oid <COMMIT-B>
155
remote: # post-receive hook
156
- remote: post-receive< <COMMIT-B> <COMMIT-A> refs/for/master/topic
156
+ remote: post-receive< <COMMIT-B> <COMMIT-A> refs/for/main/topic
157
To <URL/of/upstream.git>
158
- <OID-B>..<OID-A> HEAD -> refs/for/master/topic
158
+ <OID-B>..<OID-A> HEAD -> refs/for/main/topic
159
EOF
160
test_cmp expect actual
161
'
@@ -164,32 +164,32 @@ test_expect_success "setup proc-receive hook (option old-oid and new-oid, $PROTO
164
write_script "$upstream/hooks/proc-receive" <<-EOF
165
printf >&2 "# proc-receive hook\n"
166
test-tool proc-receive -v \
167
- -r "ok refs/for/master/topic" \
167
+ -r "ok refs/for/main/topic" \
168
-r "option old-oid $A" \
169
-r "option new-oid $B"
170
EOF
171
'
172
173
-# Refs of upstream : master(A)
174
-# Refs of workbench: master(A) tags/v123
175
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
173
+# Refs of upstream : main(A)
174
+# Refs of workbench: main(A) tags/v123
175
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
176
test_expect_success "proc-receive: report option old-oid and new-oid ($PROTOCOL)" '
177
git -C workbench push origin \
178
- HEAD:refs/for/master/topic \
178
+ HEAD:refs/for/main/topic \
179
>out 2>&1 &&
180
make_user_friendly_and_stable_output <out >actual &&
181
cat >expect <<-EOF &&
182
remote: # pre-receive hook
183
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
183
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
184
remote: # proc-receive hook
185
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
186
- remote: proc-receive> ok refs/for/master/topic
185
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
186
+ remote: proc-receive> ok refs/for/main/topic
187
remote: proc-receive> option old-oid <COMMIT-A>
188
remote: proc-receive> option new-oid <COMMIT-B>
189
remote: # post-receive hook
190
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
190
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
191
To <URL/of/upstream.git>
192
- <OID-A>..<OID-B> HEAD -> refs/for/master/topic
192
+ <OID-A>..<OID-B> HEAD -> refs/for/main/topic
193
EOF
194
test_cmp expect actual
195
'
@@ -201,7 +201,7 @@ test_expect_success "setup proc-receive hook (report with multiple rewrites, $PR
201
-r "ok refs/for/a/b/c/topic" \
202
-r "ok refs/for/next/topic" \
203
-r "option refname refs/pull/123/head" \
204
- -r "ok refs/for/master/topic" \
204
+ -r "ok refs/for/main/topic" \
205
-r "option refname refs/pull/124/head" \
206
-r "option old-oid $B" \
207
-r "option forced-update" \
@@ -209,29 +209,29 @@ test_expect_success "setup proc-receive hook (report with multiple rewrites, $PR
209
EOF
210
'
211
212
-# Refs of upstream : master(A)
213
-# Refs of workbench: master(A) tags/v123
214
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
212
+# Refs of upstream : main(A)
213
+# Refs of workbench: main(A) tags/v123
214
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
215
test_expect_success "proc-receive: report with multiple rewrites ($PROTOCOL)" '
216
git -C workbench push origin \
217
HEAD:refs/for/next/topic \
218
HEAD:refs/for/a/b/c/topic \
219
- HEAD:refs/for/master/topic \
219
+ HEAD:refs/for/main/topic \
220
>out 2>&1 &&
221
make_user_friendly_and_stable_output <out >actual &&
222
cat >expect <<-EOF &&
223
remote: # pre-receive hook
224
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
225
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/a/b/c/topic
226
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
226
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
227
remote: # proc-receive hook
228
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
229
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/a/b/c/topic
230
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
230
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
231
remote: proc-receive> ok refs/for/a/b/c/topic
232
remote: proc-receive> ok refs/for/next/topic
233
remote: proc-receive> option refname refs/pull/123/head
234
- remote: proc-receive> ok refs/for/master/topic
234
+ remote: proc-receive> ok refs/for/main/topic
235
remote: proc-receive> option refname refs/pull/124/head
236
remote: proc-receive> option old-oid <COMMIT-B>
237
remote: proc-receive> option forced-update
@@ -250,7 +250,7 @@ test_expect_success "proc-receive: report with multiple rewrites ($PROTOCOL)" '
250
git -C "$upstream" show-ref >out &&
251
make_user_friendly_and_stable_output <out >actual &&
252
cat >expect <<-EOF &&
253
- <COMMIT-A> refs/heads/master
253
+ <COMMIT-A> refs/heads/main
254
EOF
255
test_cmp expect actual
256
'
t/t5411/test-0033-report-with-options--porcelain.sh
+60
-60
@@ -7,24 +7,24 @@ test_expect_success "setup proc-receive hook (option without matching ok, $PROTO
7
EOF
8
'
9
10
-# Refs of upstream : master(A)
11
-# Refs of workbench: master(A) tags/v123
12
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
10
+# Refs of upstream : main(A)
11
+# Refs of workbench: main(A) tags/v123
12
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
13
test_expect_success "proc-receive: report option without matching ok ($PROTOCOL/porcelain)" '
14
test_must_fail git -C workbench push --porcelain origin \
15
- HEAD:refs/for/master/topic \
15
+ HEAD:refs/for/main/topic \
16
>out 2>&1 &&
17
make_user_friendly_and_stable_output <out >actual &&
18
cat >expect <<-EOF &&
19
remote: # pre-receive hook
20
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
20
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
21
remote: # proc-receive hook
22
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
22
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
23
remote: proc-receive> option refname refs/pull/123/head
24
remote: proc-receive> option old-oid <COMMIT-B>
25
remote: error: proc-receive reported "option" without a matching "ok/ng" directive
26
To <URL/of/upstream.git>
27
- ! HEAD:refs/for/master/topic [remote rejected] (proc-receive failed to report status)
27
+ ! HEAD:refs/for/main/topic [remote rejected] (proc-receive failed to report status)
28
Done
29
EOF
30
test_cmp expect actual
@@ -34,25 +34,25 @@ test_expect_success "setup proc-receive hook (option refname, $PROTOCOL/porcelai
34
write_script "$upstream/hooks/proc-receive" <<-EOF
35
printf >&2 "# proc-receive hook\n"
36
test-tool proc-receive -v \
37
- -r "ok refs/for/master/topic" \
37
+ -r "ok refs/for/main/topic" \
38
-r "option refname refs/pull/123/head"
39
EOF
40
'
41
42
-# Refs of upstream : master(A)
43
-# Refs of workbench: master(A) tags/v123
44
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
42
+# Refs of upstream : main(A)
43
+# Refs of workbench: main(A) tags/v123
44
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
45
test_expect_success "proc-receive: report option refname ($PROTOCOL/porcelain)" '
46
git -C workbench push --porcelain origin \
47
- HEAD:refs/for/master/topic \
47
+ HEAD:refs/for/main/topic \
48
>out 2>&1 &&
49
make_user_friendly_and_stable_output <out >actual &&
50
cat >expect <<-EOF &&
51
remote: # pre-receive hook
52
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
52
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
53
remote: # proc-receive hook
54
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
55
- remote: proc-receive> ok refs/for/master/topic
54
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
55
+ remote: proc-receive> ok refs/for/main/topic
56
remote: proc-receive> option refname refs/pull/123/head
57
remote: # post-receive hook
58
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/pull/123/head
@@ -67,26 +67,26 @@ test_expect_success "setup proc-receive hook (option refname and forced-update,
67
write_script "$upstream/hooks/proc-receive" <<-EOF
68
printf >&2 "# proc-receive hook\n"
69
test-tool proc-receive -v \
70
- -r "ok refs/for/master/topic" \
70
+ -r "ok refs/for/main/topic" \
71
-r "option refname refs/pull/123/head" \
72
-r "option forced-update"
73
EOF
74
'
75
76
-# Refs of upstream : master(A)
77
-# Refs of workbench: master(A) tags/v123
78
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
76
+# Refs of upstream : main(A)
77
+# Refs of workbench: main(A) tags/v123
78
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
79
test_expect_success "proc-receive: report option refname and forced-update ($PROTOCOL/porcelain)" '
80
git -C workbench push --porcelain origin \
81
- HEAD:refs/for/master/topic \
81
+ HEAD:refs/for/main/topic \
82
>out 2>&1 &&
83
make_user_friendly_and_stable_output <out >actual &&
84
cat >expect <<-EOF &&
85
remote: # pre-receive hook
86
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
86
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
87
remote: # proc-receive hook
88
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
89
- remote: proc-receive> ok refs/for/master/topic
88
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
89
+ remote: proc-receive> ok refs/for/main/topic
90
remote: proc-receive> option refname refs/pull/123/head
91
remote: proc-receive> option forced-update
92
remote: # post-receive hook
@@ -102,26 +102,26 @@ test_expect_success "setup proc-receive hook (option refname and old-oid, $PROTO
102
write_script "$upstream/hooks/proc-receive" <<-EOF
103
printf >&2 "# proc-receive hook\n"
104
test-tool proc-receive -v \
105
- -r "ok refs/for/master/topic" \
105
+ -r "ok refs/for/main/topic" \
106
-r "option refname refs/pull/123/head" \
107
-r "option old-oid $B"
108
EOF
109
'
110
111
-# Refs of upstream : master(A)
112
-# Refs of workbench: master(A) tags/v123
113
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
111
+# Refs of upstream : main(A)
112
+# Refs of workbench: main(A) tags/v123
113
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
114
test_expect_success "proc-receive: report option refname and old-oid ($PROTOCOL/porcelain)" '
115
git -C workbench push --porcelain origin \
116
- HEAD:refs/for/master/topic \
116
+ HEAD:refs/for/main/topic \
117
>out 2>&1 &&
118
make_user_friendly_and_stable_output <out >actual &&
119
cat >expect <<-EOF &&
120
remote: # pre-receive hook
121
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
121
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
122
remote: # proc-receive hook
123
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
124
- remote: proc-receive> ok refs/for/master/topic
123
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
124
+ remote: proc-receive> ok refs/for/main/topic
125
remote: proc-receive> option refname refs/pull/123/head
126
remote: proc-receive> option old-oid <COMMIT-B>
127
remote: # post-receive hook
@@ -137,30 +137,30 @@ test_expect_success "setup proc-receive hook (option old-oid, $PROTOCOL/porcelai
137
write_script "$upstream/hooks/proc-receive" <<-EOF
138
printf >&2 "# proc-receive hook\n"
139
test-tool proc-receive -v \
140
- -r "ok refs/for/master/topic" \
140
+ -r "ok refs/for/main/topic" \
141
-r "option old-oid $B"
142
EOF
143
'
144
145
-# Refs of upstream : master(A)
146
-# Refs of workbench: master(A) tags/v123
147
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
145
+# Refs of upstream : main(A)
146
+# Refs of workbench: main(A) tags/v123
147
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
148
test_expect_success "proc-receive: report option old-oid ($PROTOCOL/porcelain)" '
149
git -C workbench push --porcelain origin \
150
- HEAD:refs/for/master/topic \
150
+ HEAD:refs/for/main/topic \
151
>out 2>&1 &&
152
make_user_friendly_and_stable_output <out >actual &&
153
cat >expect <<-EOF &&
154
remote: # pre-receive hook
155
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
155
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
156
remote: # proc-receive hook
157
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
158
- remote: proc-receive> ok refs/for/master/topic
157
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
158
+ remote: proc-receive> ok refs/for/main/topic
159
remote: proc-receive> option old-oid <COMMIT-B>
160
remote: # post-receive hook
161
- remote: post-receive< <COMMIT-B> <COMMIT-A> refs/for/master/topic
161
+ remote: post-receive< <COMMIT-B> <COMMIT-A> refs/for/main/topic
162
To <URL/of/upstream.git>
163
- HEAD:refs/for/master/topic <OID-B>..<OID-A>
163
+ HEAD:refs/for/main/topic <OID-B>..<OID-A>
164
Done
165
EOF
166
test_cmp expect actual
@@ -170,32 +170,32 @@ test_expect_success "setup proc-receive hook (option old-oid and new-oid, $PROTO
170
write_script "$upstream/hooks/proc-receive" <<-EOF
171
printf >&2 "# proc-receive hook\n"
172
test-tool proc-receive -v \
173
- -r "ok refs/for/master/topic" \
173
+ -r "ok refs/for/main/topic" \
174
-r "option old-oid $A" \
175
-r "option new-oid $B"
176
EOF
177
'
178
179
-# Refs of upstream : master(A)
180
-# Refs of workbench: master(A) tags/v123
181
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
179
+# Refs of upstream : main(A)
180
+# Refs of workbench: main(A) tags/v123
181
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
182
test_expect_success "proc-receive: report option old-oid and new-oid ($PROTOCOL/porcelain)" '
183
git -C workbench push --porcelain origin \
184
- HEAD:refs/for/master/topic \
184
+ HEAD:refs/for/main/topic \
185
>out 2>&1 &&
186
make_user_friendly_and_stable_output <out >actual &&
187
cat >expect <<-EOF &&
188
remote: # pre-receive hook
189
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
189
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
190
remote: # proc-receive hook
191
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
192
- remote: proc-receive> ok refs/for/master/topic
191
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
192
+ remote: proc-receive> ok refs/for/main/topic
193
remote: proc-receive> option old-oid <COMMIT-A>
194
remote: proc-receive> option new-oid <COMMIT-B>
195
remote: # post-receive hook
196
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
196
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
197
To <URL/of/upstream.git>
198
- HEAD:refs/for/master/topic <OID-A>..<OID-B>
198
+ HEAD:refs/for/main/topic <OID-A>..<OID-B>
199
Done
200
EOF
201
test_cmp expect actual
@@ -208,7 +208,7 @@ test_expect_success "setup proc-receive hook (report with multiple rewrites, $PR
208
-r "ok refs/for/a/b/c/topic" \
209
-r "ok refs/for/next/topic" \
210
-r "option refname refs/pull/123/head" \
211
- -r "ok refs/for/master/topic" \
211
+ -r "ok refs/for/main/topic" \
212
-r "option refname refs/pull/124/head" \
213
-r "option old-oid $B" \
214
-r "option forced-update" \
@@ -217,29 +217,29 @@ test_expect_success "setup proc-receive hook (report with multiple rewrites, $PR
217
EOF
218
'
219
220
-# Refs of upstream : master(A)
221
-# Refs of workbench: master(A) tags/v123
222
-# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/master/topic(A)
220
+# Refs of upstream : main(A)
221
+# Refs of workbench: main(A) tags/v123
222
+# git push : refs/for/next/topic(A) refs/for/a/b/c/topic(A) refs/for/main/topic(A)
223
test_expect_success "proc-receive: report with multiple rewrites ($PROTOCOL/porcelain)" '
224
git -C workbench push --porcelain origin \
225
HEAD:refs/for/next/topic \
226
HEAD:refs/for/a/b/c/topic \
227
- HEAD:refs/for/master/topic \
227
+ HEAD:refs/for/main/topic \
228
>out 2>&1 &&
229
make_user_friendly_and_stable_output <out >actual &&
230
cat >expect <<-EOF &&
231
remote: # pre-receive hook
232
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
233
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/a/b/c/topic
234
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
234
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
235
remote: # proc-receive hook
236
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
237
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/a/b/c/topic
238
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
238
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
239
remote: proc-receive> ok refs/for/a/b/c/topic
240
remote: proc-receive> ok refs/for/next/topic
241
remote: proc-receive> option refname refs/pull/123/head
242
- remote: proc-receive> ok refs/for/master/topic
242
+ remote: proc-receive> ok refs/for/main/topic
243
remote: proc-receive> option refname refs/pull/124/head
244
remote: proc-receive> option old-oid <COMMIT-B>
245
remote: proc-receive> option forced-update
@@ -259,7 +259,7 @@ test_expect_success "proc-receive: report with multiple rewrites ($PROTOCOL/porc
259
git -C "$upstream" show-ref >out &&
260
make_user_friendly_and_stable_output <out >actual &&
261
cat >expect <<-EOF &&
262
- <COMMIT-A> refs/heads/master
262
+ <COMMIT-A> refs/heads/main
263
EOF
264
test_cmp expect actual
265
'
t/t5411/test-0034-report-ft.sh
+15
-15
@@ -2,43 +2,43 @@ test_expect_success "setup proc-receive hook (ft, $PROTOCOL)" '
2
write_script "$upstream/hooks/proc-receive" <<-EOF
3
printf >&2 "# proc-receive hook\n"
4
test-tool proc-receive -v \
5
- -r "ok refs/for/master/topic" \
5
+ -r "ok refs/for/main/topic" \
6
-r "option fall-through"
7
EOF
8
'
9
10
-# Refs of upstream : master(A)
11
-# Refs of workbench: master(A) tags/v123
12
-# git push : refs/for/master/topic(B)
10
+# Refs of upstream : main(A)
11
+# Refs of workbench: main(A) tags/v123
12
+# git push : refs/for/main/topic(B)
13
test_expect_success "proc-receive: fall throught, let receive-pack to execute ($PROTOCOL)" '
14
git -C workbench push origin \
15
- $B:refs/for/master/topic \
15
+ $B:refs/for/main/topic \
16
>out 2>&1 &&
17
make_user_friendly_and_stable_output <out >actual &&
18
cat >expect <<-EOF &&
19
remote: # pre-receive hook
20
- remote: pre-receive< <ZERO-OID> <COMMIT-B> refs/for/master/topic
20
+ remote: pre-receive< <ZERO-OID> <COMMIT-B> refs/for/main/topic
21
remote: # proc-receive hook
22
- remote: proc-receive< <ZERO-OID> <COMMIT-B> refs/for/master/topic
23
- remote: proc-receive> ok refs/for/master/topic
22
+ remote: proc-receive< <ZERO-OID> <COMMIT-B> refs/for/main/topic
23
+ remote: proc-receive> ok refs/for/main/topic
24
remote: proc-receive> option fall-through
25
remote: # post-receive hook
26
- remote: post-receive< <ZERO-OID> <COMMIT-B> refs/for/master/topic
26
+ remote: post-receive< <ZERO-OID> <COMMIT-B> refs/for/main/topic
27
To <URL/of/upstream.git>
28
- * [new reference] <COMMIT-B> -> refs/for/master/topic
28
+ * [new reference] <COMMIT-B> -> refs/for/main/topic
29
EOF
30
test_cmp expect actual &&
31
git -C "$upstream" show-ref >out &&
32
make_user_friendly_and_stable_output <out >actual &&
33
cat >expect <<-EOF &&
34
- <COMMIT-B> refs/for/master/topic
35
- <COMMIT-A> refs/heads/master
34
+ <COMMIT-B> refs/for/main/topic
35
+ <COMMIT-A> refs/heads/main
36
EOF
37
test_cmp expect actual
38
'
39
40
-# Refs of upstream : master(A) refs/for/master/topic(A)
41
-# Refs of workbench: master(A) tags/v123
40
+# Refs of upstream : main(A) refs/for/main/topic(A)
41
+# Refs of workbench: main(A) tags/v123
42
test_expect_success "cleanup ($PROTOCOL)" '
43
- git -C "$upstream" update-ref -d refs/for/master/topic
43
+ git -C "$upstream" update-ref -d refs/for/main/topic
44
'
t/t5411/test-0035-report-ft--porcelain.sh
+15
-15
@@ -2,44 +2,44 @@ test_expect_success "setup proc-receive hook (fall-through, $PROTOCOL/porcelain)
2
write_script "$upstream/hooks/proc-receive" <<-EOF
3
printf >&2 "# proc-receive hook\n"
4
test-tool proc-receive -v \
5
- -r "ok refs/for/master/topic" \
5
+ -r "ok refs/for/main/topic" \
6
-r "option fall-through"
7
EOF
8
'
9
10
-# Refs of upstream : master(A)
11
-# Refs of workbench: master(A) tags/v123
12
-# git push : refs/for/master/topic(B)
10
+# Refs of upstream : main(A)
11
+# Refs of workbench: main(A) tags/v123
12
+# git push : refs/for/main/topic(B)
13
test_expect_success "proc-receive: fall throught, let receive-pack to execute ($PROTOCOL/porcelain)" '
14
git -C workbench push --porcelain origin \
15
- $B:refs/for/master/topic \
15
+ $B:refs/for/main/topic \
16
>out 2>&1 &&
17
make_user_friendly_and_stable_output <out >actual &&
18
cat >expect <<-EOF &&
19
remote: # pre-receive hook
20
- remote: pre-receive< <ZERO-OID> <COMMIT-B> refs/for/master/topic
20
+ remote: pre-receive< <ZERO-OID> <COMMIT-B> refs/for/main/topic
21
remote: # proc-receive hook
22
- remote: proc-receive< <ZERO-OID> <COMMIT-B> refs/for/master/topic
23
- remote: proc-receive> ok refs/for/master/topic
22
+ remote: proc-receive< <ZERO-OID> <COMMIT-B> refs/for/main/topic
23
+ remote: proc-receive> ok refs/for/main/topic
24
remote: proc-receive> option fall-through
25
remote: # post-receive hook
26
- remote: post-receive< <ZERO-OID> <COMMIT-B> refs/for/master/topic
26
+ remote: post-receive< <ZERO-OID> <COMMIT-B> refs/for/main/topic
27
To <URL/of/upstream.git>
28
- * <COMMIT-B>:refs/for/master/topic [new reference]
28
+ * <COMMIT-B>:refs/for/main/topic [new reference]
29
Done
30
EOF
31
test_cmp expect actual &&
32
git -C "$upstream" show-ref >out &&
33
make_user_friendly_and_stable_output <out >actual &&
34
cat >expect <<-EOF &&
35
- <COMMIT-B> refs/for/master/topic
36
- <COMMIT-A> refs/heads/master
35
+ <COMMIT-B> refs/for/main/topic
36
+ <COMMIT-A> refs/heads/main
37
EOF
38
test_cmp expect actual
39
'
40
41
-# Refs of upstream : master(A) refs/for/master/topic(A)
42
-# Refs of workbench: master(A) tags/v123
41
+# Refs of upstream : main(A) refs/for/main/topic(A)
42
+# Refs of workbench: main(A) tags/v123
43
test_expect_success "cleanup ($PROTOCOL/porcelain)" '
44
- git -C "$upstream" update-ref -d refs/for/master/topic
44
+ git -C "$upstream" update-ref -d refs/for/main/topic
45
'
t/t5411/test-0036-report-multi-rewrite-for-one-ref.sh
+45
-45
@@ -17,50 +17,50 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, no
17
write_script "$upstream/hooks/proc-receive" <<-EOF
18
printf >&2 "# proc-receive hook\n"
19
test-tool proc-receive -v \
20
- -r "ok refs/for/master/topic" \
20
+ -r "ok refs/for/main/topic" \
21
-r "option old-oid $A" \
22
-r "option new-oid $B" \
23
- -r "ok refs/for/master/topic" \
23
+ -r "ok refs/for/main/topic" \
24
-r "option refname refs/changes/24/124/1" \
25
-r "option old-oid $ZERO_OID" \
26
-r "option new-oid $A" \
27
- -r "ok refs/for/master/topic" \
27
+ -r "ok refs/for/main/topic" \
28
-r "option refname refs/changes/25/125/1" \
29
-r "option old-oid $A" \
30
-r "option new-oid $B"
31
EOF
32
'
33
34
-# Refs of upstream : master(A)
35
-# Refs of workbench: master(A) tags/v123
36
-# git push : refs/for/master/topic(A)
34
+# Refs of upstream : main(A)
35
+# Refs of workbench: main(A) tags/v123
36
+# git push : refs/for/main/topic(A)
37
test_expect_success "proc-receive: multiple rewrite for one ref, no refname for the 1st rewrite ($PROTOCOL)" '
38
git -C workbench push origin \
39
- HEAD:refs/for/master/topic \
39
+ HEAD:refs/for/main/topic \
40
>out 2>&1 &&
41
make_user_friendly_and_stable_output <out >actual &&
42
cat >expect <<-EOF &&
43
remote: # pre-receive hook
44
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
44
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
45
remote: # proc-receive hook
46
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
47
- remote: proc-receive> ok refs/for/master/topic
46
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
47
+ remote: proc-receive> ok refs/for/main/topic
48
remote: proc-receive> option old-oid <COMMIT-A>
49
remote: proc-receive> option new-oid <COMMIT-B>
50
- remote: proc-receive> ok refs/for/master/topic
50
+ remote: proc-receive> ok refs/for/main/topic
51
remote: proc-receive> option refname refs/changes/24/124/1
52
remote: proc-receive> option old-oid <ZERO-OID>
53
remote: proc-receive> option new-oid <COMMIT-A>
54
- remote: proc-receive> ok refs/for/master/topic
54
+ remote: proc-receive> ok refs/for/main/topic
55
remote: proc-receive> option refname refs/changes/25/125/1
56
remote: proc-receive> option old-oid <COMMIT-A>
57
remote: proc-receive> option new-oid <COMMIT-B>
58
remote: # post-receive hook
59
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
59
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
60
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/changes/24/124/1
61
remote: post-receive< <COMMIT-A> <COMMIT-B> refs/changes/25/125/1
62
To <URL/of/upstream.git>
63
- <OID-A>..<OID-B> HEAD -> refs/for/master/topic
63
+ <OID-A>..<OID-B> HEAD -> refs/for/main/topic
64
* [new reference] HEAD -> refs/changes/24/124/1
65
<OID-A>..<OID-B> HEAD -> refs/changes/25/125/1
66
EOF
@@ -68,7 +68,7 @@ test_expect_success "proc-receive: multiple rewrite for one ref, no refname for
68
git -C "$upstream" show-ref >out &&
69
make_user_friendly_and_stable_output <out >actual &&
70
cat >expect <<-EOF &&
71
- <COMMIT-A> refs/heads/master
71
+ <COMMIT-A> refs/heads/main
72
EOF
73
test_cmp expect actual
74
'
@@ -80,10 +80,10 @@ test_expect_success "proc-receive: check remote-tracking #1 ($PROTOCOL)" '
80
cat >expect <<-EOF &&
81
<COMMIT-A> refs/t/changes/24/124/1
82
<COMMIT-B> refs/t/changes/25/125/1
83
- <COMMIT-B> refs/t/for/master/topic
83
+ <COMMIT-B> refs/t/for/main/topic
84
EOF
85
test_cmp expect actual &&
86
- git -C workbench update-ref -d refs/t/for/master/topic &&
86
+ git -C workbench update-ref -d refs/t/for/main/topic &&
87
git -C workbench update-ref -d refs/t/changes/24/124/1 &&
88
git -C workbench update-ref -d refs/t/changes/25/125/1
89
'
@@ -92,14 +92,14 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, no
92
write_script "$upstream/hooks/proc-receive" <<-EOF
93
printf >&2 "# proc-receive hook\n"
94
test-tool proc-receive -v \
95
- -r "ok refs/for/master/topic" \
95
+ -r "ok refs/for/main/topic" \
96
-r "option refname refs/changes/24/124/1" \
97
-r "option old-oid $ZERO_OID" \
98
-r "option new-oid $A" \
99
- -r "ok refs/for/master/topic" \
99
+ -r "ok refs/for/main/topic" \
100
-r "option old-oid $A" \
101
-r "option new-oid $B" \
102
- -r "ok refs/for/master/topic" \
102
+ -r "ok refs/for/main/topic" \
103
-r "option refname refs/changes/25/125/1" \
104
-r "option old-oid $B" \
105
-r "option new-oid $A" \
@@ -107,45 +107,45 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, no
107
EOF
108
'
109
110
-# Refs of upstream : master(A)
111
-# Refs of workbench: master(A) tags/v123
112
-# git push : refs/for/master/topic(A)
110
+# Refs of upstream : main(A)
111
+# Refs of workbench: main(A) tags/v123
112
+# git push : refs/for/main/topic(A)
113
test_expect_success "proc-receive: multiple rewrites for one ref, no refname for the 2nd rewrite ($PROTOCOL)" '
114
git -C workbench push origin \
115
- HEAD:refs/for/master/topic \
115
+ HEAD:refs/for/main/topic \
116
>out 2>&1 &&
117
make_user_friendly_and_stable_output <out >actual &&
118
cat >expect <<-EOF &&
119
remote: # pre-receive hook
120
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
120
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
121
remote: # proc-receive hook
122
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
123
- remote: proc-receive> ok refs/for/master/topic
122
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
123
+ remote: proc-receive> ok refs/for/main/topic
124
remote: proc-receive> option refname refs/changes/24/124/1
125
remote: proc-receive> option old-oid <ZERO-OID>
126
remote: proc-receive> option new-oid <COMMIT-A>
127
- remote: proc-receive> ok refs/for/master/topic
127
+ remote: proc-receive> ok refs/for/main/topic
128
remote: proc-receive> option old-oid <COMMIT-A>
129
remote: proc-receive> option new-oid <COMMIT-B>
130
- remote: proc-receive> ok refs/for/master/topic
130
+ remote: proc-receive> ok refs/for/main/topic
131
remote: proc-receive> option refname refs/changes/25/125/1
132
remote: proc-receive> option old-oid <COMMIT-B>
133
remote: proc-receive> option new-oid <COMMIT-A>
134
remote: proc-receive> option forced-update
135
remote: # post-receive hook
136
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/changes/24/124/1
137
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
137
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
138
remote: post-receive< <COMMIT-B> <COMMIT-A> refs/changes/25/125/1
139
To <URL/of/upstream.git>
140
* [new reference] HEAD -> refs/changes/24/124/1
141
- <OID-A>..<OID-B> HEAD -> refs/for/master/topic
141
+ <OID-A>..<OID-B> HEAD -> refs/for/main/topic
142
+ <OID-B>...<OID-A> HEAD -> refs/changes/25/125/1 (forced update)
143
EOF
144
test_cmp expect actual &&
145
git -C "$upstream" show-ref >out &&
146
make_user_friendly_and_stable_output <out >actual &&
147
cat >expect <<-EOF &&
148
- <COMMIT-A> refs/heads/master
148
+ <COMMIT-A> refs/heads/main
149
EOF
150
test_cmp expect actual
151
'
@@ -157,10 +157,10 @@ test_expect_success "proc-receive: check remote-tracking #2 ($PROTOCOL)" '
157
cat >expect <<-EOF &&
158
<COMMIT-A> refs/t/changes/24/124/1
159
<COMMIT-A> refs/t/changes/25/125/1
160
- <COMMIT-B> refs/t/for/master/topic
160
+ <COMMIT-B> refs/t/for/main/topic
161
EOF
162
test_cmp expect actual &&
163
- git -C workbench update-ref -d refs/t/for/master/topic &&
163
+ git -C workbench update-ref -d refs/t/for/main/topic &&
164
git -C workbench update-ref -d refs/t/changes/24/124/1 &&
165
git -C workbench update-ref -d refs/t/changes/25/125/1
166
'
@@ -169,31 +169,31 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, $PR
169
write_script "$upstream/hooks/proc-receive" <<-EOF
170
printf >&2 "# proc-receive hook\n"
171
test-tool proc-receive -v \
172
- -r "ok refs/for/master/topic" \
172
+ -r "ok refs/for/main/topic" \
173
-r "option refname refs/changes/23/123/1" \
174
- -r "ok refs/for/master/topic" \
174
+ -r "ok refs/for/main/topic" \
175
-r "option refname refs/changes/24/124/2" \
176
-r "option old-oid $A" \
177
-r "option new-oid $B"
178
EOF
179
'
180
181
-# Refs of upstream : master(A)
182
-# Refs of workbench: master(A) tags/v123
183
-# git push : refs/for/master/topic(A)
181
+# Refs of upstream : main(A)
182
+# Refs of workbench: main(A) tags/v123
183
+# git push : refs/for/main/topic(A)
184
test_expect_success "proc-receive: multiple rewrites for one ref ($PROTOCOL)" '
185
git -C workbench push origin \
186
- HEAD:refs/for/master/topic \
186
+ HEAD:refs/for/main/topic \
187
>out 2>&1 &&
188
make_user_friendly_and_stable_output <out >actual &&
189
cat >expect <<-EOF &&
190
remote: # pre-receive hook
191
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
191
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
192
remote: # proc-receive hook
193
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
194
- remote: proc-receive> ok refs/for/master/topic
193
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
194
+ remote: proc-receive> ok refs/for/main/topic
195
remote: proc-receive> option refname refs/changes/23/123/1
196
- remote: proc-receive> ok refs/for/master/topic
196
+ remote: proc-receive> ok refs/for/main/topic
197
remote: proc-receive> option refname refs/changes/24/124/2
198
remote: proc-receive> option old-oid <COMMIT-A>
199
remote: proc-receive> option new-oid <COMMIT-B>
@@ -208,7 +208,7 @@ test_expect_success "proc-receive: multiple rewrites for one ref ($PROTOCOL)" '
208
git -C "$upstream" show-ref >out &&
209
make_user_friendly_and_stable_output <out >actual &&
210
cat >expect <<-EOF &&
211
- <COMMIT-A> refs/heads/master
211
+ <COMMIT-A> refs/heads/main
212
EOF
213
test_cmp expect actual
214
'
t/t5411/test-0037-report-multi-rewrite-for-one-ref--porcelain.sh
+41
-41
@@ -2,50 +2,50 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, no
2
write_script "$upstream/hooks/proc-receive" <<-EOF
3
printf >&2 "# proc-receive hook\n"
4
test-tool proc-receive -v \
5
- -r "ok refs/for/master/topic" \
5
+ -r "ok refs/for/main/topic" \
6
-r "option old-oid $A" \
7
-r "option new-oid $B" \
8
- -r "ok refs/for/master/topic" \
8
+ -r "ok refs/for/main/topic" \
9
-r "option refname refs/changes/24/124/1" \
10
-r "option old-oid $ZERO_OID" \
11
-r "option new-oid $A" \
12
- -r "ok refs/for/master/topic" \
12
+ -r "ok refs/for/main/topic" \
13
-r "option refname refs/changes/25/125/1" \
14
-r "option old-oid $A" \
15
-r "option new-oid $B"
16
EOF
17
'
18
19
-# Refs of upstream : master(A)
20
-# Refs of workbench: master(A) tags/v123
21
-# git push : refs/for/master/topic(A)
19
+# Refs of upstream : main(A)
20
+# Refs of workbench: main(A) tags/v123
21
+# git push : refs/for/main/topic(A)
22
test_expect_success "proc-receive: multiple rewrite for one ref, no refname for the 1st rewrite ($PROTOCOL/porcelain)" '
23
git -C workbench push --porcelain origin \
24
- HEAD:refs/for/master/topic \
24
+ HEAD:refs/for/main/topic \
25
>out 2>&1 &&
26
make_user_friendly_and_stable_output <out >actual &&
27
cat >expect <<-EOF &&
28
remote: # pre-receive hook
29
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
29
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
30
remote: # proc-receive hook
31
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
32
- remote: proc-receive> ok refs/for/master/topic
31
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
32
+ remote: proc-receive> ok refs/for/main/topic
33
remote: proc-receive> option old-oid <COMMIT-A>
34
remote: proc-receive> option new-oid <COMMIT-B>
35
- remote: proc-receive> ok refs/for/master/topic
35
+ remote: proc-receive> ok refs/for/main/topic
36
remote: proc-receive> option refname refs/changes/24/124/1
37
remote: proc-receive> option old-oid <ZERO-OID>
38
remote: proc-receive> option new-oid <COMMIT-A>
39
- remote: proc-receive> ok refs/for/master/topic
39
+ remote: proc-receive> ok refs/for/main/topic
40
remote: proc-receive> option refname refs/changes/25/125/1
41
remote: proc-receive> option old-oid <COMMIT-A>
42
remote: proc-receive> option new-oid <COMMIT-B>
43
remote: # post-receive hook
44
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
44
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
45
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/changes/24/124/1
46
remote: post-receive< <COMMIT-A> <COMMIT-B> refs/changes/25/125/1
47
To <URL/of/upstream.git>
48
- HEAD:refs/for/master/topic <OID-A>..<OID-B>
48
+ HEAD:refs/for/main/topic <OID-A>..<OID-B>
49
* HEAD:refs/changes/24/124/1 [new reference]
50
HEAD:refs/changes/25/125/1 <OID-A>..<OID-B>
51
Done
@@ -54,7 +54,7 @@ test_expect_success "proc-receive: multiple rewrite for one ref, no refname for
54
git -C "$upstream" show-ref >out &&
55
make_user_friendly_and_stable_output <out >actual &&
56
cat >expect <<-EOF &&
57
- <COMMIT-A> refs/heads/master
57
+ <COMMIT-A> refs/heads/main
58
EOF
59
test_cmp expect actual
60
'
@@ -63,14 +63,14 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, no
63
write_script "$upstream/hooks/proc-receive" <<-EOF
64
printf >&2 "# proc-receive hook\n"
65
test-tool proc-receive -v \
66
- -r "ok refs/for/master/topic" \
66
+ -r "ok refs/for/main/topic" \
67
-r "option refname refs/changes/24/124/1" \
68
-r "option old-oid $ZERO_OID" \
69
-r "option new-oid $A" \
70
- -r "ok refs/for/master/topic" \
70
+ -r "ok refs/for/main/topic" \
71
-r "option old-oid $A" \
72
-r "option new-oid $B" \
73
- -r "ok refs/for/master/topic" \
73
+ -r "ok refs/for/main/topic" \
74
-r "option refname refs/changes/25/125/1" \
75
-r "option old-oid $B" \
76
-r "option new-oid $A" \
@@ -78,38 +78,38 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, no
78
EOF
79
'
80
81
-# Refs of upstream : master(A)
82
-# Refs of workbench: master(A) tags/v123
83
-# git push : refs/for/master/topic(A)
81
+# Refs of upstream : main(A)
82
+# Refs of workbench: main(A) tags/v123
83
+# git push : refs/for/main/topic(A)
84
test_expect_success "proc-receive: multiple rewrites for one ref, no refname for the 2nd rewrite ($PROTOCOL/porcelain)" '
85
git -C workbench push --porcelain origin \
86
- HEAD:refs/for/master/topic \
86
+ HEAD:refs/for/main/topic \
87
>out 2>&1 &&
88
make_user_friendly_and_stable_output <out >actual &&
89
cat >expect <<-EOF &&
90
remote: # pre-receive hook
91
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
91
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
92
remote: # proc-receive hook
93
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
94
- remote: proc-receive> ok refs/for/master/topic
93
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
94
+ remote: proc-receive> ok refs/for/main/topic
95
remote: proc-receive> option refname refs/changes/24/124/1
96
remote: proc-receive> option old-oid <ZERO-OID>
97
remote: proc-receive> option new-oid <COMMIT-A>
98
- remote: proc-receive> ok refs/for/master/topic
98
+ remote: proc-receive> ok refs/for/main/topic
99
remote: proc-receive> option old-oid <COMMIT-A>
100
remote: proc-receive> option new-oid <COMMIT-B>
101
- remote: proc-receive> ok refs/for/master/topic
101
+ remote: proc-receive> ok refs/for/main/topic
102
remote: proc-receive> option refname refs/changes/25/125/1
103
remote: proc-receive> option old-oid <COMMIT-B>
104
remote: proc-receive> option new-oid <COMMIT-A>
105
remote: proc-receive> option forced-update
106
remote: # post-receive hook
107
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/changes/24/124/1
108
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
108
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
109
remote: post-receive< <COMMIT-B> <COMMIT-A> refs/changes/25/125/1
110
To <URL/of/upstream.git>
111
* HEAD:refs/changes/24/124/1 [new reference]
112
- HEAD:refs/for/master/topic <OID-A>..<OID-B>
112
+ HEAD:refs/for/main/topic <OID-A>..<OID-B>
113
+ HEAD:refs/changes/25/125/1 <OID-B>...<OID-A> (forced update)
114
Done
115
EOF
@@ -117,7 +117,7 @@ test_expect_success "proc-receive: multiple rewrites for one ref, no refname for
117
git -C "$upstream" show-ref >out &&
118
make_user_friendly_and_stable_output <out >actual &&
119
cat >expect <<-EOF &&
120
- <COMMIT-A> refs/heads/master
120
+ <COMMIT-A> refs/heads/main
121
EOF
122
test_cmp expect actual
123
'
@@ -126,31 +126,31 @@ test_expect_success "setup proc-receive hook (multiple rewrites for one ref, $PR
126
write_script "$upstream/hooks/proc-receive" <<-EOF
127
printf >&2 "# proc-receive hook\n"
128
test-tool proc-receive -v \
129
- -r "ok refs/for/master/topic" \
129
+ -r "ok refs/for/main/topic" \
130
-r "option refname refs/changes/23/123/1" \
131
- -r "ok refs/for/master/topic" \
131
+ -r "ok refs/for/main/topic" \
132
-r "option refname refs/changes/24/124/2" \
133
-r "option old-oid $A" \
134
-r "option new-oid $B"
135
EOF
136
'
137
138
-# Refs of upstream : master(A)
139
-# Refs of workbench: master(A) tags/v123
140
-# git push : refs/for/master/topic(A)
138
+# Refs of upstream : main(A)
139
+# Refs of workbench: main(A) tags/v123
140
+# git push : refs/for/main/topic(A)
141
test_expect_success "proc-receive: multiple rewrites for one ref ($PROTOCOL/porcelain)" '
142
git -C workbench push --porcelain origin \
143
- HEAD:refs/for/master/topic \
143
+ HEAD:refs/for/main/topic \
144
>out 2>&1 &&
145
make_user_friendly_and_stable_output <out >actual &&
146
cat >expect <<-EOF &&
147
remote: # pre-receive hook
148
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
148
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
149
remote: # proc-receive hook
150
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
151
- remote: proc-receive> ok refs/for/master/topic
150
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
151
+ remote: proc-receive> ok refs/for/main/topic
152
remote: proc-receive> option refname refs/changes/23/123/1
153
- remote: proc-receive> ok refs/for/master/topic
153
+ remote: proc-receive> ok refs/for/main/topic
154
remote: proc-receive> option refname refs/changes/24/124/2
155
remote: proc-receive> option old-oid <COMMIT-A>
156
remote: proc-receive> option new-oid <COMMIT-B>
@@ -166,7 +166,7 @@ test_expect_success "proc-receive: multiple rewrites for one ref ($PROTOCOL/porc
166
git -C "$upstream" show-ref >out &&
167
make_user_friendly_and_stable_output <out >actual &&
168
cat >expect <<-EOF &&
169
- <COMMIT-A> refs/heads/master
169
+ <COMMIT-A> refs/heads/main
170
EOF
171
test_cmp expect actual
172
'
t/t5411/test-0038-report-mixed-refs.sh
+20
-20
@@ -4,63 +4,63 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
4
test-tool proc-receive -v \
5
-r "ok refs/for/next/topic2" \
6
-r "ng refs/for/next/topic1 fail to call Web API" \
7
- -r "ok refs/for/master/topic" \
8
- -r "option refname refs/for/master/topic" \
7
+ -r "ok refs/for/main/topic" \
8
+ -r "option refname refs/for/main/topic" \
9
-r "option old-oid $A" \
10
-r "option new-oid $B"
11
EOF
12
'
13
14
-# Refs of upstream : master(A)
15
-# Refs of workbench: master(A) tags/v123
16
-# git push : (B) bar(A) baz(A) refs/for/next/topic(A) foo(A) refs/for/master/topic(A)
14
+# Refs of upstream : main(A)
15
+# Refs of workbench: main(A) tags/v123
16
+# git push : (B) bar(A) baz(A) refs/for/next/topic(A) foo(A) refs/for/main/topic(A)
17
test_expect_success "proc-receive: report update of mixed refs ($PROTOCOL)" '
18
test_must_fail git -C workbench push origin \
19
- $B:refs/heads/master \
19
+ $B:refs/heads/main \
20
HEAD:refs/heads/bar \
21
HEAD:refs/heads/baz \
22
HEAD:refs/for/next/topic2 \
23
HEAD:refs/for/next/topic1 \
24
HEAD:refs/heads/foo \
25
- HEAD:refs/for/master/topic \
25
+ HEAD:refs/for/main/topic \
26
HEAD:refs/for/next/topic3 \
27
>out 2>&1 &&
28
make_user_friendly_and_stable_output <out >actual &&
29
cat >expect <<-EOF &&
30
remote: # pre-receive hook
31
- remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/master
31
+ remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/main
32
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/bar
33
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/baz
34
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic2
35
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic1
36
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/foo
37
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
37
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
38
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic3
39
remote: # proc-receive hook
40
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic2
41
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic1
42
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
42
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
43
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic3
44
remote: proc-receive> ok refs/for/next/topic2
45
remote: proc-receive> ng refs/for/next/topic1 fail to call Web API
46
- remote: proc-receive> ok refs/for/master/topic
47
- remote: proc-receive> option refname refs/for/master/topic
46
+ remote: proc-receive> ok refs/for/main/topic
47
+ remote: proc-receive> option refname refs/for/main/topic
48
remote: proc-receive> option old-oid <COMMIT-A>
49
remote: proc-receive> option new-oid <COMMIT-B>
50
remote: # post-receive hook
51
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/heads/master
51
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/heads/main
52
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/heads/bar
53
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/heads/baz
54
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic2
55
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/heads/foo
56
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
56
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
57
To <URL/of/upstream.git>
58
- <OID-A>..<OID-B> <COMMIT-B> -> master
58
+ <OID-A>..<OID-B> <COMMIT-B> -> main
59
* [new branch] HEAD -> bar
60
* [new branch] HEAD -> baz
61
* [new reference] HEAD -> refs/for/next/topic2
62
* [new branch] HEAD -> foo
63
- <OID-A>..<OID-B> HEAD -> refs/for/master/topic
63
+ <OID-A>..<OID-B> HEAD -> refs/for/main/topic
64
! [remote rejected] HEAD -> refs/for/next/topic1 (fail to call Web API)
65
! [remote rejected] HEAD -> refs/for/next/topic3 (proc-receive failed to report status)
66
EOF
@@ -71,17 +71,17 @@ test_expect_success "proc-receive: report update of mixed refs ($PROTOCOL)" '
71
<COMMIT-A> refs/heads/bar
72
<COMMIT-A> refs/heads/baz
73
<COMMIT-A> refs/heads/foo
74
- <COMMIT-B> refs/heads/master
74
+ <COMMIT-B> refs/heads/main
75
EOF
76
test_cmp expect actual
77
'
78
79
-# Refs of upstream : master(B) foo(A) bar(A)) baz(A)
80
-# Refs of workbench: master(A) tags/v123
79
+# Refs of upstream : main(B) foo(A) bar(A)) baz(A)
80
+# Refs of workbench: main(A) tags/v123
81
test_expect_success "cleanup ($PROTOCOL)" '
82
(
83
cd "$upstream" &&
84
- git update-ref refs/heads/master $A &&
84
+ git update-ref refs/heads/main $A &&
85
git update-ref -d refs/heads/foo &&
86
git update-ref -d refs/heads/bar &&
87
git update-ref -d refs/heads/baz
t/t5411/test-0039-report-mixed-refs--porcelain.sh
+20
-20
@@ -4,63 +4,63 @@ test_expect_success "setup proc-receive hook ($PROTOCOL/porcelain)" '
4
test-tool proc-receive -v \
5
-r "ok refs/for/next/topic2" \
6
-r "ng refs/for/next/topic1 fail to call Web API" \
7
- -r "ok refs/for/master/topic" \
8
- -r "option refname refs/for/master/topic" \
7
+ -r "ok refs/for/main/topic" \
8
+ -r "option refname refs/for/main/topic" \
9
-r "option old-oid $A" \
10
-r "option new-oid $B"
11
EOF
12
'
13
14
-# Refs of upstream : master(A)
15
-# Refs of workbench: master(A) tags/v123
16
-# git push : (B) bar(A) baz(A) refs/for/next/topic(A) foo(A) refs/for/master/topic(A)
14
+# Refs of upstream : main(A)
15
+# Refs of workbench: main(A) tags/v123
16
+# git push : (B) bar(A) baz(A) refs/for/next/topic(A) foo(A) refs/for/main/topic(A)
17
test_expect_success "proc-receive: report update of mixed refs ($PROTOCOL/porcelain)" '
18
test_must_fail git -C workbench push --porcelain origin \
19
- $B:refs/heads/master \
19
+ $B:refs/heads/main \
20
HEAD:refs/heads/bar \
21
HEAD:refs/heads/baz \
22
HEAD:refs/for/next/topic2 \
23
HEAD:refs/for/next/topic1 \
24
HEAD:refs/heads/foo \
25
- HEAD:refs/for/master/topic \
25
+ HEAD:refs/for/main/topic \
26
HEAD:refs/for/next/topic3 \
27
>out 2>&1 &&
28
make_user_friendly_and_stable_output <out >actual &&
29
cat >expect <<-EOF &&
30
remote: # pre-receive hook
31
- remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/master
31
+ remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/main
32
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/bar
33
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/baz
34
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic2
35
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic1
36
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/foo
37
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
37
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
38
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic3
39
remote: # proc-receive hook
40
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic2
41
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic1
42
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
42
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
43
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic3
44
remote: proc-receive> ok refs/for/next/topic2
45
remote: proc-receive> ng refs/for/next/topic1 fail to call Web API
46
- remote: proc-receive> ok refs/for/master/topic
47
- remote: proc-receive> option refname refs/for/master/topic
46
+ remote: proc-receive> ok refs/for/main/topic
47
+ remote: proc-receive> option refname refs/for/main/topic
48
remote: proc-receive> option old-oid <COMMIT-A>
49
remote: proc-receive> option new-oid <COMMIT-B>
50
remote: # post-receive hook
51
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/heads/master
51
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/heads/main
52
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/heads/bar
53
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/heads/baz
54
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic2
55
remote: post-receive< <ZERO-OID> <COMMIT-A> refs/heads/foo
56
- remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/master/topic
56
+ remote: post-receive< <COMMIT-A> <COMMIT-B> refs/for/main/topic
57
To <URL/of/upstream.git>
58
- <COMMIT-B>:refs/heads/master <OID-A>..<OID-B>
58
+ <COMMIT-B>:refs/heads/main <OID-A>..<OID-B>
59
* HEAD:refs/heads/bar [new branch]
60
* HEAD:refs/heads/baz [new branch]
61
* HEAD:refs/for/next/topic2 [new reference]
62
* HEAD:refs/heads/foo [new branch]
63
- HEAD:refs/for/master/topic <OID-A>..<OID-B>
63
+ HEAD:refs/for/main/topic <OID-A>..<OID-B>
64
! HEAD:refs/for/next/topic1 [remote rejected] (fail to call Web API)
65
! HEAD:refs/for/next/topic3 [remote rejected] (proc-receive failed to report status)
66
Done
@@ -72,17 +72,17 @@ test_expect_success "proc-receive: report update of mixed refs ($PROTOCOL/porcel
72
<COMMIT-A> refs/heads/bar
73
<COMMIT-A> refs/heads/baz
74
<COMMIT-A> refs/heads/foo
75
- <COMMIT-B> refs/heads/master
75
+ <COMMIT-B> refs/heads/main
76
EOF
77
test_cmp expect actual
78
'
79
80
-# Refs of upstream : master(B) foo(A) bar(A)) baz(A)
81
-# Refs of workbench: master(A) tags/v123
80
+# Refs of upstream : main(B) foo(A) bar(A)) baz(A)
81
+# Refs of workbench: main(A) tags/v123
82
test_expect_success "cleanup ($PROTOCOL/porcelain)" '
83
(
84
cd "$upstream" &&
85
- git update-ref refs/heads/master $A &&
85
+ git update-ref refs/heads/main $A &&
86
git update-ref -d refs/heads/foo &&
87
git update-ref -d refs/heads/bar &&
88
git update-ref -d refs/heads/baz
t/t5411/test-0040-process-all-refs.sh
+21
-21
@@ -3,12 +3,12 @@ test_expect_success "config receive.procReceiveRefs = refs ($PROTOCOL)" '
3
git -C "$upstream" config --add receive.procReceiveRefs refs
4
'
5
6
-# Refs of upstream : master(A)
7
-# Refs of workbench: master(A) tags/v123
6
+# Refs of upstream : main(A)
7
+# Refs of workbench: main(A) tags/v123
8
test_expect_success "setup upstream branches ($PROTOCOL)" '
9
(
10
cd "$upstream" &&
11
- git update-ref refs/heads/master $B &&
11
+ git update-ref refs/heads/main $B &&
12
git update-ref refs/heads/foo $A &&
13
git update-ref refs/heads/bar $A &&
14
git update-ref refs/heads/baz $A
@@ -20,13 +20,13 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
20
write_script "$upstream/hooks/proc-receive" <<-EOF
21
printf >&2 "# proc-receive hook\n"
22
test-tool proc-receive -v \
23
- -r "ok refs/heads/master" \
23
+ -r "ok refs/heads/main" \
24
-r "option fall-through" \
25
-r "ok refs/heads/foo" \
26
-r "option fall-through" \
27
-r "ok refs/heads/bar" \
28
-r "option fall-through" \
29
- -r "ok refs/for/master/topic" \
29
+ -r "ok refs/for/main/topic" \
30
-r "option refname refs/pull/123/head" \
31
-r "option old-oid $A" \
32
-r "option new-oid $B" \
@@ -38,15 +38,15 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
38
EOF
39
'
40
41
-# Refs of upstream : master(B) foo(A) bar(A)) baz(A)
42
-# Refs of workbench: master(A) tags/v123
43
-# git push -f : master(A) (NULL) (B) refs/for/master/topic(A) refs/for/next/topic(A)
41
+# Refs of upstream : main(B) foo(A) bar(A)) baz(A)
42
+# Refs of workbench: main(A) tags/v123
43
+# git push -f : main(A) (NULL) (B) refs/for/main/topic(A) refs/for/next/topic(A)
44
test_expect_success "proc-receive: process all refs ($PROTOCOL)" '
45
git -C workbench push -f origin \
46
- HEAD:refs/heads/master \
46
+ HEAD:refs/heads/main \
47
:refs/heads/foo \
48
$B:refs/heads/bar \
49
- HEAD:refs/for/master/topic \
49
+ HEAD:refs/for/main/topic \
50
HEAD:refs/for/next/topic \
51
>out 2>&1 &&
52
make_user_friendly_and_stable_output <out >actual &&
@@ -54,22 +54,22 @@ test_expect_success "proc-receive: process all refs ($PROTOCOL)" '
54
remote: # pre-receive hook
55
remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/bar
56
remote: pre-receive< <COMMIT-A> <ZERO-OID> refs/heads/foo
57
- remote: pre-receive< <COMMIT-B> <COMMIT-A> refs/heads/master
58
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
57
+ remote: pre-receive< <COMMIT-B> <COMMIT-A> refs/heads/main
58
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
59
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
60
remote: # proc-receive hook
61
remote: proc-receive< <COMMIT-A> <COMMIT-B> refs/heads/bar
62
remote: proc-receive< <COMMIT-A> <ZERO-OID> refs/heads/foo
63
- remote: proc-receive< <COMMIT-B> <COMMIT-A> refs/heads/master
64
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
63
+ remote: proc-receive< <COMMIT-B> <COMMIT-A> refs/heads/main
64
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
65
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
66
- remote: proc-receive> ok refs/heads/master
66
+ remote: proc-receive> ok refs/heads/main
67
remote: proc-receive> option fall-through
68
remote: proc-receive> ok refs/heads/foo
69
remote: proc-receive> option fall-through
70
remote: proc-receive> ok refs/heads/bar
71
remote: proc-receive> option fall-through
72
- remote: proc-receive> ok refs/for/master/topic
72
+ remote: proc-receive> ok refs/for/main/topic
73
remote: proc-receive> option refname refs/pull/123/head
74
remote: proc-receive> option old-oid <COMMIT-A>
75
remote: proc-receive> option new-oid <COMMIT-B>
@@ -81,13 +81,13 @@ test_expect_success "proc-receive: process all refs ($PROTOCOL)" '
81
remote: # post-receive hook
82
remote: post-receive< <COMMIT-A> <COMMIT-B> refs/heads/bar
83
remote: post-receive< <COMMIT-A> <ZERO-OID> refs/heads/foo
84
- remote: post-receive< <COMMIT-B> <COMMIT-A> refs/heads/master
84
+ remote: post-receive< <COMMIT-B> <COMMIT-A> refs/heads/main
85
remote: post-receive< <COMMIT-A> <COMMIT-B> refs/pull/123/head
86
remote: post-receive< <COMMIT-B> <COMMIT-A> refs/pull/124/head
87
To <URL/of/upstream.git>
88
<OID-A>..<OID-B> <COMMIT-B> -> bar
89
- [deleted] foo
90
- + <OID-B>...<OID-A> HEAD -> master (forced update)
90
+ + <OID-B>...<OID-A> HEAD -> main (forced update)
91
<OID-A>..<OID-B> HEAD -> refs/pull/123/head
92
+ <OID-B>...<OID-A> HEAD -> refs/pull/124/head (forced update)
93
EOF
@@ -97,13 +97,13 @@ test_expect_success "proc-receive: process all refs ($PROTOCOL)" '
97
cat >expect <<-EOF &&
98
<COMMIT-B> refs/heads/bar
99
<COMMIT-A> refs/heads/baz
100
- <COMMIT-A> refs/heads/master
100
+ <COMMIT-A> refs/heads/main
101
EOF
102
test_cmp expect actual
103
'
104
105
-# Refs of upstream : master(A) bar(A) baz(B)
106
-# Refs of workbench: master(A) tags/v123
105
+# Refs of upstream : main(A) bar(A) baz(B)
106
+# Refs of workbench: main(A) tags/v123
107
test_expect_success "cleanup ($PROTOCOL)" '
108
(
109
cd "$upstream" &&
t/t5411/test-0041-process-all-refs--porcelain.sh
+21
-21
@@ -3,12 +3,12 @@ test_expect_success "config receive.procReceiveRefs = refs ($PROTOCOL/porcelain)
3
git -C "$upstream" config --add receive.procReceiveRefs refs
4
'
5
6
-# Refs of upstream : master(A)
7
-# Refs of workbench: master(A) tags/v123
6
+# Refs of upstream : main(A)
7
+# Refs of workbench: main(A) tags/v123
8
test_expect_success "setup upstream branches ($PROTOCOL/porcelain)" '
9
(
10
cd "$upstream" &&
11
- git update-ref refs/heads/master $B &&
11
+ git update-ref refs/heads/main $B &&
12
git update-ref refs/heads/foo $A &&
13
git update-ref refs/heads/bar $A &&
14
git update-ref refs/heads/baz $A
@@ -20,13 +20,13 @@ test_expect_success "setup proc-receive hook ($PROTOCOL/porcelain)" '
20
write_script "$upstream/hooks/proc-receive" <<-EOF
21
printf >&2 "# proc-receive hook\n"
22
test-tool proc-receive -v \
23
- -r "ok refs/heads/master" \
23
+ -r "ok refs/heads/main" \
24
-r "option fall-through" \
25
-r "ok refs/heads/foo" \
26
-r "option fall-through" \
27
-r "ok refs/heads/bar" \
28
-r "option fall-through" \
29
- -r "ok refs/for/master/topic" \
29
+ -r "ok refs/for/main/topic" \
30
-r "option refname refs/pull/123/head" \
31
-r "option old-oid $A" \
32
-r "option new-oid $B" \
@@ -38,15 +38,15 @@ test_expect_success "setup proc-receive hook ($PROTOCOL/porcelain)" '
38
EOF
39
'
40
41
-# Refs of upstream : master(B) foo(A) bar(A)) baz(A)
42
-# Refs of workbench: master(A) tags/v123
43
-# git push -f : master(A) (NULL) (B) refs/for/master/topic(A) refs/for/next/topic(A)
41
+# Refs of upstream : main(B) foo(A) bar(A)) baz(A)
42
+# Refs of workbench: main(A) tags/v123
43
+# git push -f : main(A) (NULL) (B) refs/for/main/topic(A) refs/for/next/topic(A)
44
test_expect_success "proc-receive: process all refs ($PROTOCOL/porcelain)" '
45
git -C workbench push --porcelain -f origin \
46
- HEAD:refs/heads/master \
46
+ HEAD:refs/heads/main \
47
:refs/heads/foo \
48
$B:refs/heads/bar \
49
- HEAD:refs/for/master/topic \
49
+ HEAD:refs/for/main/topic \
50
HEAD:refs/for/next/topic \
51
>out 2>&1 &&
52
make_user_friendly_and_stable_output <out >actual &&
@@ -54,22 +54,22 @@ test_expect_success "proc-receive: process all refs ($PROTOCOL/porcelain)" '
54
remote: # pre-receive hook
55
remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/bar
56
remote: pre-receive< <COMMIT-A> <ZERO-OID> refs/heads/foo
57
- remote: pre-receive< <COMMIT-B> <COMMIT-A> refs/heads/master
58
- remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
57
+ remote: pre-receive< <COMMIT-B> <COMMIT-A> refs/heads/main
58
+ remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
59
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
60
remote: # proc-receive hook
61
remote: proc-receive< <COMMIT-A> <COMMIT-B> refs/heads/bar
62
remote: proc-receive< <COMMIT-A> <ZERO-OID> refs/heads/foo
63
- remote: proc-receive< <COMMIT-B> <COMMIT-A> refs/heads/master
64
- remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/master/topic
63
+ remote: proc-receive< <COMMIT-B> <COMMIT-A> refs/heads/main
64
+ remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/main/topic
65
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/for/next/topic
66
- remote: proc-receive> ok refs/heads/master
66
+ remote: proc-receive> ok refs/heads/main
67
remote: proc-receive> option fall-through
68
remote: proc-receive> ok refs/heads/foo
69
remote: proc-receive> option fall-through
70
remote: proc-receive> ok refs/heads/bar
71
remote: proc-receive> option fall-through
72
- remote: proc-receive> ok refs/for/master/topic
72
+ remote: proc-receive> ok refs/for/main/topic
73
remote: proc-receive> option refname refs/pull/123/head
74
remote: proc-receive> option old-oid <COMMIT-A>
75
remote: proc-receive> option new-oid <COMMIT-B>
@@ -81,13 +81,13 @@ test_expect_success "proc-receive: process all refs ($PROTOCOL/porcelain)" '
81
remote: # post-receive hook
82
remote: post-receive< <COMMIT-A> <COMMIT-B> refs/heads/bar
83
remote: post-receive< <COMMIT-A> <ZERO-OID> refs/heads/foo
84
- remote: post-receive< <COMMIT-B> <COMMIT-A> refs/heads/master
84
+ remote: post-receive< <COMMIT-B> <COMMIT-A> refs/heads/main
85
remote: post-receive< <COMMIT-A> <COMMIT-B> refs/pull/123/head
86
remote: post-receive< <COMMIT-B> <COMMIT-A> refs/pull/124/head
87
To <URL/of/upstream.git>
88
<COMMIT-B>:refs/heads/bar <OID-A>..<OID-B>
89
- :refs/heads/foo [deleted]
90
- + HEAD:refs/heads/master <OID-B>...<OID-A> (forced update)
90
+ + HEAD:refs/heads/main <OID-B>...<OID-A> (forced update)
91
HEAD:refs/pull/123/head <OID-A>..<OID-B>
92
+ HEAD:refs/pull/124/head <OID-B>...<OID-A> (forced update)
93
Done
@@ -98,13 +98,13 @@ test_expect_success "proc-receive: process all refs ($PROTOCOL/porcelain)" '
98
cat >expect <<-EOF &&
99
<COMMIT-B> refs/heads/bar
100
<COMMIT-A> refs/heads/baz
101
- <COMMIT-A> refs/heads/master
101
+ <COMMIT-A> refs/heads/main
102
EOF
103
test_cmp expect actual
104
'
105
106
-# Refs of upstream : master(A) bar(A) baz(B)
107
-# Refs of workbench: master(A) tags/v123
106
+# Refs of upstream : main(A) bar(A) baz(B)
107
+# Refs of workbench: main(A) tags/v123
108
test_expect_success "cleanup ($PROTOCOL/porcelain)" '
109
(
110
cd "$upstream" &&
t/t5411/test-0050-proc-receive-refs-with-modifiers.sh
+21
-21
@@ -2,7 +2,7 @@ test_expect_success "config receive.procReceiveRefs with modifiers ($PROTOCOL)"
2
(
3
cd "$upstream" &&
4
git config --unset-all receive.procReceiveRefs &&
5
- git config --add receive.procReceiveRefs m:refs/heads/master &&
5
+ git config --add receive.procReceiveRefs m:refs/heads/main &&
6
git config --add receive.procReceiveRefs ad:refs/heads &&
7
git config --add receive.procReceiveRefs "a!:refs/heads"
8
)
@@ -12,7 +12,7 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
12
write_script "$upstream/hooks/proc-receive" <<-EOF
13
printf >&2 "# proc-receive hook\n"
14
test-tool proc-receive -v \
15
- -r "ok refs/heads/master" \
15
+ -r "ok refs/heads/main" \
16
-r "option refname refs/pull/123/head" \
17
-r "option old-oid $A" \
18
-r "option new-oid $B" \
@@ -21,22 +21,22 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
21
EOF
22
'
23
24
-# Refs of upstream : master(A)
25
-# Refs of workbench: master(A) tags/v123
26
-# git push : master(B) tags/v123
24
+# Refs of upstream : main(A)
25
+# Refs of workbench: main(A) tags/v123
26
+# git push : main(B) tags/v123
27
test_expect_success "proc-receive: update branch and new tag ($PROTOCOL)" '
28
git -C workbench push origin \
29
- $B:refs/heads/master \
29
+ $B:refs/heads/main \
30
v123 >out 2>&1 &&
31
make_user_friendly_and_stable_output <out >actual &&
32
cat >expect <<-EOF &&
33
remote: # pre-receive hook
34
- remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/master
34
+ remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/main
35
remote: pre-receive< <ZERO-OID> <TAG-v123> refs/tags/v123
36
remote: # proc-receive hook
37
- remote: proc-receive< <COMMIT-A> <COMMIT-B> refs/heads/master
37
+ remote: proc-receive< <COMMIT-A> <COMMIT-B> refs/heads/main
38
remote: proc-receive< <ZERO-OID> <TAG-v123> refs/tags/v123
39
- remote: proc-receive> ok refs/heads/master
39
+ remote: proc-receive> ok refs/heads/main
40
remote: proc-receive> option refname refs/pull/123/head
41
remote: proc-receive> option old-oid <COMMIT-A>
42
remote: proc-receive> option new-oid <COMMIT-B>
@@ -53,20 +53,20 @@ test_expect_success "proc-receive: update branch and new tag ($PROTOCOL)" '
53
git -C "$upstream" show-ref >out &&
54
make_user_friendly_and_stable_output <out >actual &&
55
cat >expect <<-EOF &&
56
- <COMMIT-A> refs/heads/master
56
+ <COMMIT-A> refs/heads/main
57
EOF
58
test_cmp expect actual
59
'
60
61
-# Refs of upstream : master(A)
62
-# Refs of workbench: master(A) tags/v123
61
+# Refs of upstream : main(A)
62
+# Refs of workbench: main(A) tags/v123
63
test_expect_success "setup upstream: create tags/v123 ($PROTOCOL)" '
64
git -C "$upstream" update-ref refs/heads/topic $A &&
65
git -C "$upstream" update-ref refs/tags/v123 $TAG &&
66
git -C "$upstream" show-ref >out &&
67
make_user_friendly_and_stable_output <out >actual &&
68
cat >expect <<-EOF &&
69
- <COMMIT-A> refs/heads/master
69
+ <COMMIT-A> refs/heads/main
70
<COMMIT-A> refs/heads/topic
71
<TAG-v123> refs/tags/v123
72
EOF
@@ -77,7 +77,7 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
77
write_script "$upstream/hooks/proc-receive" <<-EOF
78
printf >&2 "# proc-receive hook\n"
79
test-tool proc-receive -v \
80
- -r "ok refs/heads/master" \
80
+ -r "ok refs/heads/main" \
81
-r "option refname refs/pull/123/head" \
82
-r "option old-oid $A" \
83
-r "option new-oid $ZERO_OID" \
@@ -87,26 +87,26 @@ test_expect_success "setup proc-receive hook ($PROTOCOL)" '
87
EOF
88
'
89
90
-# Refs of upstream : master(A) topic(A) tags/v123
91
-# Refs of workbench: master(A) tags/v123
90
+# Refs of upstream : main(A) topic(A) tags/v123
91
+# Refs of workbench: main(A) tags/v123
92
# git push : NULL topic(B) NULL next(A)
93
test_expect_success "proc-receive: create/delete branch, and delete tag ($PROTOCOL)" '
94
git -C workbench push origin \
95
- :refs/heads/master \
95
+ :refs/heads/main \
96
$B:refs/heads/topic \
97
$A:refs/heads/next \
98
:refs/tags/v123 >out 2>&1 &&
99
make_user_friendly_and_stable_output <out >actual &&
100
cat >expect <<-EOF &&
101
remote: # pre-receive hook
102
- remote: pre-receive< <COMMIT-A> <ZERO-OID> refs/heads/master
102
+ remote: pre-receive< <COMMIT-A> <ZERO-OID> refs/heads/main
103
remote: pre-receive< <COMMIT-A> <COMMIT-B> refs/heads/topic
104
remote: pre-receive< <TAG-v123> <ZERO-OID> refs/tags/v123
105
remote: pre-receive< <ZERO-OID> <COMMIT-A> refs/heads/next
106
remote: # proc-receive hook
107
- remote: proc-receive< <COMMIT-A> <ZERO-OID> refs/heads/master
107
+ remote: proc-receive< <COMMIT-A> <ZERO-OID> refs/heads/main
108
remote: proc-receive< <ZERO-OID> <COMMIT-A> refs/heads/next
109
- remote: proc-receive> ok refs/heads/master
109
+ remote: proc-receive> ok refs/heads/main
110
remote: proc-receive> option refname refs/pull/123/head
111
remote: proc-receive> option old-oid <COMMIT-A>
112
remote: proc-receive> option new-oid <ZERO-OID>
@@ -128,7 +128,7 @@ test_expect_success "proc-receive: create/delete branch, and delete tag ($PROTOC
128
git -C "$upstream" show-ref >out &&
129
make_user_friendly_and_stable_output <out >actual &&
130
cat >expect <<-EOF &&
131
- <COMMIT-A> refs/heads/master
131
+ <COMMIT-A> refs/heads/main
132
<COMMIT-B> refs/heads/topic
133
EOF
134
test_cmp expect actual