@@ -23,6 +23,7 @@ const mockPushProcessors = {
23
23
checkAuthorEmails : sinon . stub ( ) ,
24
24
checkUserPushPermission : sinon . stub ( ) ,
25
25
checkIfWaitingAuth : sinon . stub ( ) ,
26
+ checkHiddenCommits : sinon . stub ( ) ,
26
27
pullRemote : sinon . stub ( ) ,
27
28
writePack : sinon . stub ( ) ,
28
29
preReceive : sinon . stub ( ) ,
@@ -39,6 +40,7 @@ mockPushProcessors.checkCommitMessages.displayName = 'checkCommitMessages';
39
40
mockPushProcessors . checkAuthorEmails . displayName = 'checkAuthorEmails' ;
40
41
mockPushProcessors . checkUserPushPermission . displayName = 'checkUserPushPermission' ;
41
42
mockPushProcessors . checkIfWaitingAuth . displayName = 'checkIfWaitingAuth' ;
43
+ mockPushProcessors . checkHiddenCommits . displayName = 'checkHiddenCommits' ;
42
44
mockPushProcessors . pullRemote . displayName = 'pullRemote' ;
43
45
mockPushProcessors . writePack . displayName = 'writePack' ;
44
46
mockPushProcessors . preReceive . displayName = 'preReceive' ;
@@ -110,7 +112,9 @@ describe('proxy chain', function () {
110
112
mockPushProcessors . checkCommitMessages . resolves ( continuingAction ) ;
111
113
mockPushProcessors . checkAuthorEmails . resolves ( continuingAction ) ;
112
114
mockPushProcessors . checkUserPushPermission . resolves ( continuingAction ) ;
113
-
115
+ mockPushProcessors . checkHiddenCommits . resolves ( continuingAction ) ;
116
+ mockPushProcessors . pullRemote . resolves ( continuingAction ) ;
117
+ mockPushProcessors . writePack . resolves ( continuingAction ) ;
114
118
// this stops the chain from further execution
115
119
mockPushProcessors . checkIfWaitingAuth . resolves ( {
116
120
type : 'push' ,
@@ -126,7 +130,10 @@ describe('proxy chain', function () {
126
130
expect ( mockPushProcessors . checkAuthorEmails . called ) . to . be . true ;
127
131
expect ( mockPushProcessors . checkUserPushPermission . called ) . to . be . true ;
128
132
expect ( mockPushProcessors . checkIfWaitingAuth . called ) . to . be . true ;
129
- expect ( mockPushProcessors . pullRemote . called ) . to . be . false ;
133
+ expect ( mockPushProcessors . pullRemote . called ) . to . be . true ;
134
+ expect ( mockPushProcessors . checkHiddenCommits . called ) . to . be . true ;
135
+ expect ( mockPushProcessors . writePack . called ) . to . be . true ;
136
+ expect ( mockPushProcessors . getMissingData . called ) . to . be . false ;
130
137
expect ( mockPushProcessors . audit . called ) . to . be . true ;
131
138
132
139
expect ( result . type ) . to . equal ( 'push' ) ;
@@ -143,6 +150,9 @@ describe('proxy chain', function () {
143
150
mockPushProcessors . checkCommitMessages . resolves ( continuingAction ) ;
144
151
mockPushProcessors . checkAuthorEmails . resolves ( continuingAction ) ;
145
152
mockPushProcessors . checkUserPushPermission . resolves ( continuingAction ) ;
153
+ mockPushProcessors . checkHiddenCommits . resolves ( continuingAction ) ;
154
+ mockPushProcessors . pullRemote . resolves ( continuingAction ) ;
155
+ mockPushProcessors . writePack . resolves ( continuingAction ) ;
146
156
// this stops the chain from further execution
147
157
mockPushProcessors . checkIfWaitingAuth . resolves ( {
148
158
type : 'push' ,
@@ -158,7 +168,10 @@ describe('proxy chain', function () {
158
168
expect ( mockPushProcessors . checkAuthorEmails . called ) . to . be . true ;
159
169
expect ( mockPushProcessors . checkUserPushPermission . called ) . to . be . true ;
160
170
expect ( mockPushProcessors . checkIfWaitingAuth . called ) . to . be . true ;
161
- expect ( mockPushProcessors . pullRemote . called ) . to . be . false ;
171
+ expect ( mockPushProcessors . pullRemote . called ) . to . be . true ;
172
+ expect ( mockPushProcessors . checkHiddenCommits . called ) . to . be . true ;
173
+ expect ( mockPushProcessors . writePack . called ) . to . be . true ;
174
+ expect ( mockPushProcessors . getMissingData . called ) . to . be . false ;
162
175
expect ( mockPushProcessors . audit . called ) . to . be . true ;
163
176
164
177
expect ( result . type ) . to . equal ( 'push' ) ;
@@ -178,6 +191,7 @@ describe('proxy chain', function () {
178
191
mockPushProcessors . checkIfWaitingAuth . resolves ( continuingAction ) ;
179
192
mockPushProcessors . pullRemote . resolves ( continuingAction ) ;
180
193
mockPushProcessors . writePack . resolves ( continuingAction ) ;
194
+ mockPushProcessors . checkHiddenCommits . resolves ( continuingAction ) ;
181
195
mockPushProcessors . preReceive . resolves ( continuingAction ) ;
182
196
mockPushProcessors . getDiff . resolves ( continuingAction ) ;
183
197
mockPushProcessors . clearBareClone . resolves ( continuingAction ) ;
@@ -195,6 +209,7 @@ describe('proxy chain', function () {
195
209
expect ( mockPushProcessors . checkUserPushPermission . called ) . to . be . true ;
196
210
expect ( mockPushProcessors . checkIfWaitingAuth . called ) . to . be . true ;
197
211
expect ( mockPushProcessors . pullRemote . called ) . to . be . true ;
212
+ expect ( mockPushProcessors . checkHiddenCommits . called ) . to . be . true ;
198
213
expect ( mockPushProcessors . writePack . called ) . to . be . true ;
199
214
expect ( mockPushProcessors . preReceive . called ) . to . be . true ;
200
215
expect ( mockPushProcessors . getDiff . called ) . to . be . true ;
@@ -270,6 +285,7 @@ describe('proxy chain', function () {
270
285
mockPushProcessors . checkIfWaitingAuth . resolves ( action ) ;
271
286
mockPushProcessors . pullRemote . resolves ( action ) ;
272
287
mockPushProcessors . writePack . resolves ( action ) ;
288
+ mockPushProcessors . checkHiddenCommits . resolves ( action ) ;
273
289
274
290
mockPushProcessors . preReceive . resolves ( {
275
291
...action ,
@@ -316,6 +332,7 @@ describe('proxy chain', function () {
316
332
mockPushProcessors . checkIfWaitingAuth . resolves ( action ) ;
317
333
mockPushProcessors . pullRemote . resolves ( action ) ;
318
334
mockPushProcessors . writePack . resolves ( action ) ;
335
+ mockPushProcessors . checkHiddenCommits . resolves ( action ) ;
319
336
320
337
mockPushProcessors . preReceive . resolves ( {
321
338
...action ,
@@ -363,6 +380,7 @@ describe('proxy chain', function () {
363
380
mockPushProcessors . checkIfWaitingAuth . resolves ( action ) ;
364
381
mockPushProcessors . pullRemote . resolves ( action ) ;
365
382
mockPushProcessors . writePack . resolves ( action ) ;
383
+ mockPushProcessors . checkHiddenCommits . resolves ( action ) ;
366
384
367
385
mockPushProcessors . preReceive . resolves ( {
368
386
...action ,
@@ -409,6 +427,7 @@ describe('proxy chain', function () {
409
427
mockPushProcessors . checkIfWaitingAuth . resolves ( action ) ;
410
428
mockPushProcessors . pullRemote . resolves ( action ) ;
411
429
mockPushProcessors . writePack . resolves ( action ) ;
430
+ mockPushProcessors . checkHiddenCommits . resolves ( action ) ;
412
431
413
432
mockPushProcessors . preReceive . resolves ( {
414
433
...action ,
0 commit comments