@@ -17,7 +17,7 @@ func TestBuildTreeFromFiles(t *testing.T) {
17
17
name : "no files" ,
18
18
files : []* models.File {},
19
19
expected : & Node [models.File ]{
20
- Path : "" ,
20
+ path : "" ,
21
21
Children : nil ,
22
22
},
23
23
},
@@ -32,18 +32,18 @@ func TestBuildTreeFromFiles(t *testing.T) {
32
32
},
33
33
},
34
34
expected : & Node [models.File ]{
35
- Path : "" ,
35
+ path : "" ,
36
36
Children : []* Node [models.File ]{
37
37
{
38
- Path : "dir1" ,
38
+ path : "dir1" ,
39
39
Children : []* Node [models.File ]{
40
40
{
41
41
File : & models.File {Path : "dir1/a" },
42
- Path : "dir1/a" ,
42
+ path : "dir1/a" ,
43
43
},
44
44
{
45
45
File : & models.File {Path : "dir1/b" },
46
- Path : "dir1/b" ,
46
+ path : "dir1/b" ,
47
47
},
48
48
},
49
49
},
@@ -61,24 +61,24 @@ func TestBuildTreeFromFiles(t *testing.T) {
61
61
},
62
62
},
63
63
expected : & Node [models.File ]{
64
- Path : "" ,
64
+ path : "" ,
65
65
Children : []* Node [models.File ]{
66
66
{
67
- Path : "dir1/dir3" ,
67
+ path : "dir1/dir3" ,
68
68
Children : []* Node [models.File ]{
69
69
{
70
70
File : & models.File {Path : "dir1/dir3/a" },
71
- Path : "dir1/dir3/a" ,
71
+ path : "dir1/dir3/a" ,
72
72
},
73
73
},
74
74
CompressionLevel : 1 ,
75
75
},
76
76
{
77
- Path : "dir2/dir4" ,
77
+ path : "dir2/dir4" ,
78
78
Children : []* Node [models.File ]{
79
79
{
80
80
File : & models.File {Path : "dir2/dir4/b" },
81
- Path : "dir2/dir4/b" ,
81
+ path : "dir2/dir4/b" ,
82
82
},
83
83
},
84
84
CompressionLevel : 1 ,
@@ -97,15 +97,15 @@ func TestBuildTreeFromFiles(t *testing.T) {
97
97
},
98
98
},
99
99
expected : & Node [models.File ]{
100
- Path : "" ,
100
+ path : "" ,
101
101
Children : []* Node [models.File ]{
102
102
{
103
103
File : & models.File {Path : "a" },
104
- Path : "a" ,
104
+ path : "a" ,
105
105
},
106
106
{
107
107
File : & models.File {Path : "b" },
108
- Path : "b" ,
108
+ path : "b" ,
109
109
},
110
110
},
111
111
},
@@ -125,21 +125,21 @@ func TestBuildTreeFromFiles(t *testing.T) {
125
125
},
126
126
},
127
127
expected : & Node [models.File ]{
128
- Path : "" ,
128
+ path : "" ,
129
129
// it is a little strange that we're not bubbling up our merge conflict
130
130
// here but we are technically still in tree mode and that's the rule
131
131
Children : []* Node [models.File ]{
132
132
{
133
133
File : & models.File {Path : "a" },
134
- Path : "a" ,
134
+ path : "a" ,
135
135
},
136
136
{
137
137
File : & models.File {Path : "b" },
138
- Path : "b" ,
138
+ path : "b" ,
139
139
},
140
140
{
141
141
File : & models.File {Path : "z" , HasMergeConflicts : true },
142
- Path : "z" ,
142
+ path : "z" ,
143
143
},
144
144
},
145
145
},
@@ -164,7 +164,7 @@ func TestBuildFlatTreeFromFiles(t *testing.T) {
164
164
name : "no files" ,
165
165
files : []* models.File {},
166
166
expected : & Node [models.File ]{
167
- Path : "" ,
167
+ path : "" ,
168
168
Children : []* Node [models.File ]{},
169
169
},
170
170
},
@@ -179,16 +179,16 @@ func TestBuildFlatTreeFromFiles(t *testing.T) {
179
179
},
180
180
},
181
181
expected : & Node [models.File ]{
182
- Path : "" ,
182
+ path : "" ,
183
183
Children : []* Node [models.File ]{
184
184
{
185
185
File : & models.File {Path : "dir1/a" },
186
- Path : "dir1/a" ,
186
+ path : "dir1/a" ,
187
187
CompressionLevel : 0 ,
188
188
},
189
189
{
190
190
File : & models.File {Path : "dir1/b" },
191
- Path : "dir1/b" ,
191
+ path : "dir1/b" ,
192
192
CompressionLevel : 0 ,
193
193
},
194
194
},
@@ -205,16 +205,16 @@ func TestBuildFlatTreeFromFiles(t *testing.T) {
205
205
},
206
206
},
207
207
expected : & Node [models.File ]{
208
- Path : "" ,
208
+ path : "" ,
209
209
Children : []* Node [models.File ]{
210
210
{
211
211
File : & models.File {Path : "dir1/a" },
212
- Path : "dir1/a" ,
212
+ path : "dir1/a" ,
213
213
CompressionLevel : 0 ,
214
214
},
215
215
{
216
216
File : & models.File {Path : "dir2/b" },
217
- Path : "dir2/b" ,
217
+ path : "dir2/b" ,
218
218
CompressionLevel : 0 ,
219
219
},
220
220
},
@@ -231,15 +231,15 @@ func TestBuildFlatTreeFromFiles(t *testing.T) {
231
231
},
232
232
},
233
233
expected : & Node [models.File ]{
234
- Path : "" ,
234
+ path : "" ,
235
235
Children : []* Node [models.File ]{
236
236
{
237
237
File : & models.File {Path : "a" },
238
- Path : "a" ,
238
+ path : "a" ,
239
239
},
240
240
{
241
241
File : & models.File {Path : "b" },
242
- Path : "b" ,
242
+ path : "b" ,
243
243
},
244
244
},
245
245
},
@@ -273,31 +273,31 @@ func TestBuildFlatTreeFromFiles(t *testing.T) {
273
273
},
274
274
},
275
275
expected : & Node [models.File ]{
276
- Path : "" ,
276
+ path : "" ,
277
277
Children : []* Node [models.File ]{
278
278
{
279
279
File : & models.File {Path : "c1" , HasMergeConflicts : true },
280
- Path : "c1" ,
280
+ path : "c1" ,
281
281
},
282
282
{
283
283
File : & models.File {Path : "c2" , HasMergeConflicts : true },
284
- Path : "c2" ,
284
+ path : "c2" ,
285
285
},
286
286
{
287
287
File : & models.File {Path : "b1" , Tracked : true },
288
- Path : "b1" ,
288
+ path : "b1" ,
289
289
},
290
290
{
291
291
File : & models.File {Path : "b2" , Tracked : true },
292
- Path : "b2" ,
292
+ path : "b2" ,
293
293
},
294
294
{
295
295
File : & models.File {Path : "a1" , Tracked : false },
296
- Path : "a1" ,
296
+ path : "a1" ,
297
297
},
298
298
{
299
299
File : & models.File {Path : "a2" , Tracked : false },
300
- Path : "a2" ,
300
+ path : "a2" ,
301
301
},
302
302
},
303
303
},
@@ -322,7 +322,7 @@ func TestBuildTreeFromCommitFiles(t *testing.T) {
322
322
name : "no files" ,
323
323
files : []* models.CommitFile {},
324
324
expected : & Node [models.CommitFile ]{
325
- Path : "" ,
325
+ path : "" ,
326
326
Children : nil ,
327
327
},
328
328
},
@@ -337,18 +337,18 @@ func TestBuildTreeFromCommitFiles(t *testing.T) {
337
337
},
338
338
},
339
339
expected : & Node [models.CommitFile ]{
340
- Path : "" ,
340
+ path : "" ,
341
341
Children : []* Node [models.CommitFile ]{
342
342
{
343
- Path : "dir1" ,
343
+ path : "dir1" ,
344
344
Children : []* Node [models.CommitFile ]{
345
345
{
346
346
File : & models.CommitFile {Path : "dir1/a" },
347
- Path : "dir1/a" ,
347
+ path : "dir1/a" ,
348
348
},
349
349
{
350
350
File : & models.CommitFile {Path : "dir1/b" },
351
- Path : "dir1/b" ,
351
+ path : "dir1/b" ,
352
352
},
353
353
},
354
354
},
@@ -366,24 +366,24 @@ func TestBuildTreeFromCommitFiles(t *testing.T) {
366
366
},
367
367
},
368
368
expected : & Node [models.CommitFile ]{
369
- Path : "" ,
369
+ path : "" ,
370
370
Children : []* Node [models.CommitFile ]{
371
371
{
372
- Path : "dir1/dir3" ,
372
+ path : "dir1/dir3" ,
373
373
Children : []* Node [models.CommitFile ]{
374
374
{
375
375
File : & models.CommitFile {Path : "dir1/dir3/a" },
376
- Path : "dir1/dir3/a" ,
376
+ path : "dir1/dir3/a" ,
377
377
},
378
378
},
379
379
CompressionLevel : 1 ,
380
380
},
381
381
{
382
- Path : "dir2/dir4" ,
382
+ path : "dir2/dir4" ,
383
383
Children : []* Node [models.CommitFile ]{
384
384
{
385
385
File : & models.CommitFile {Path : "dir2/dir4/b" },
386
- Path : "dir2/dir4/b" ,
386
+ path : "dir2/dir4/b" ,
387
387
},
388
388
},
389
389
CompressionLevel : 1 ,
@@ -402,15 +402,15 @@ func TestBuildTreeFromCommitFiles(t *testing.T) {
402
402
},
403
403
},
404
404
expected : & Node [models.CommitFile ]{
405
- Path : "" ,
405
+ path : "" ,
406
406
Children : []* Node [models.CommitFile ]{
407
407
{
408
408
File : & models.CommitFile {Path : "a" },
409
- Path : "a" ,
409
+ path : "a" ,
410
410
},
411
411
{
412
412
File : & models.CommitFile {Path : "b" },
413
- Path : "b" ,
413
+ path : "b" ,
414
414
},
415
415
},
416
416
},
@@ -435,7 +435,7 @@ func TestBuildFlatTreeFromCommitFiles(t *testing.T) {
435
435
name : "no files" ,
436
436
files : []* models.CommitFile {},
437
437
expected : & Node [models.CommitFile ]{
438
- Path : "" ,
438
+ path : "" ,
439
439
Children : []* Node [models.CommitFile ]{},
440
440
},
441
441
},
@@ -450,16 +450,16 @@ func TestBuildFlatTreeFromCommitFiles(t *testing.T) {
450
450
},
451
451
},
452
452
expected : & Node [models.CommitFile ]{
453
- Path : "" ,
453
+ path : "" ,
454
454
Children : []* Node [models.CommitFile ]{
455
455
{
456
456
File : & models.CommitFile {Path : "dir1/a" },
457
- Path : "dir1/a" ,
457
+ path : "dir1/a" ,
458
458
CompressionLevel : 0 ,
459
459
},
460
460
{
461
461
File : & models.CommitFile {Path : "dir1/b" },
462
- Path : "dir1/b" ,
462
+ path : "dir1/b" ,
463
463
CompressionLevel : 0 ,
464
464
},
465
465
},
@@ -476,16 +476,16 @@ func TestBuildFlatTreeFromCommitFiles(t *testing.T) {
476
476
},
477
477
},
478
478
expected : & Node [models.CommitFile ]{
479
- Path : "" ,
479
+ path : "" ,
480
480
Children : []* Node [models.CommitFile ]{
481
481
{
482
482
File : & models.CommitFile {Path : "dir1/a" },
483
- Path : "dir1/a" ,
483
+ path : "dir1/a" ,
484
484
CompressionLevel : 0 ,
485
485
},
486
486
{
487
487
File : & models.CommitFile {Path : "dir2/b" },
488
- Path : "dir2/b" ,
488
+ path : "dir2/b" ,
489
489
CompressionLevel : 0 ,
490
490
},
491
491
},
@@ -502,15 +502,15 @@ func TestBuildFlatTreeFromCommitFiles(t *testing.T) {
502
502
},
503
503
},
504
504
expected : & Node [models.CommitFile ]{
505
- Path : "" ,
505
+ path : "" ,
506
506
Children : []* Node [models.CommitFile ]{
507
507
{
508
508
File : & models.CommitFile {Path : "a" },
509
- Path : "a" ,
509
+ path : "a" ,
510
510
},
511
511
{
512
512
File : & models.CommitFile {Path : "b" },
513
- Path : "b" ,
513
+ path : "b" ,
514
514
},
515
515
},
516
516
},
0 commit comments