@@ -40,7 +40,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
40
40
endIdx int
41
41
showGraph bool
42
42
bisectInfo * git_commands.BisectInfo
43
- showYouAreHereLabel bool
44
43
expected string
45
44
focus bool
46
45
}{
@@ -223,12 +222,11 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
223
222
showGraph : true ,
224
223
bisectInfo : git_commands .NewNullBisectInfo (),
225
224
cherryPickedCommitHashSet : set .New [string ](),
226
- showYouAreHereLabel : true ,
227
225
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
228
226
expected : formatExpected (`
229
227
hash1 pick commit1
230
228
hash2 pick commit2
231
- hash3 ◯ <-- YOU ARE HERE --- commit3
229
+ hash3 ◯ commit3
232
230
hash4 ◯ commit4
233
231
hash5 ◯ commit5
234
232
` ),
@@ -247,11 +245,10 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
247
245
showGraph : true ,
248
246
bisectInfo : git_commands .NewNullBisectInfo (),
249
247
cherryPickedCommitHashSet : set .New [string ](),
250
- showYouAreHereLabel : true ,
251
248
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
252
249
expected : formatExpected (`
253
250
hash2 pick commit2
254
- hash3 ◯ <-- YOU ARE HERE --- commit3
251
+ hash3 ◯ commit3
255
252
hash4 ◯ commit4
256
253
hash5 ◯ commit5
257
254
` ),
@@ -270,7 +267,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
270
267
showGraph : true ,
271
268
bisectInfo : git_commands .NewNullBisectInfo (),
272
269
cherryPickedCommitHashSet : set .New [string ](),
273
- showYouAreHereLabel : true ,
274
270
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
275
271
expected : formatExpected (`
276
272
hash4 ◯ commit4
@@ -291,7 +287,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
291
287
showGraph : true ,
292
288
bisectInfo : git_commands .NewNullBisectInfo (),
293
289
cherryPickedCommitHashSet : set .New [string ](),
294
- showYouAreHereLabel : true ,
295
290
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
296
291
expected : formatExpected (`
297
292
hash1 pick commit1
@@ -312,7 +307,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
312
307
showGraph : true ,
313
308
bisectInfo : git_commands .NewNullBisectInfo (),
314
309
cherryPickedCommitHashSet : set .New [string ](),
315
- showYouAreHereLabel : true ,
316
310
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
317
311
expected : formatExpected (`
318
312
hash5 ◯ commit5
@@ -332,33 +326,12 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
332
326
showGraph : true ,
333
327
bisectInfo : git_commands .NewNullBisectInfo (),
334
328
cherryPickedCommitHashSet : set .New [string ](),
335
- showYouAreHereLabel : true ,
336
329
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
337
330
expected : formatExpected (`
338
331
hash1 pick commit1
339
332
hash2 pick commit2
340
333
` ),
341
334
},
342
- {
343
- testName : "don't show YOU ARE HERE label when not asked for (e.g. in branches panel)" ,
344
- commits : []* models.Commit {
345
- {Name : "commit1" , Hash : "hash1" , Parents : []string {"hash2" }, Action : todo .Pick },
346
- {Name : "commit2" , Hash : "hash2" , Parents : []string {"hash3" }},
347
- {Name : "commit3" , Hash : "hash3" , Parents : []string {"hash4" }},
348
- },
349
- startIdx : 0 ,
350
- endIdx : 3 ,
351
- showGraph : true ,
352
- bisectInfo : git_commands .NewNullBisectInfo (),
353
- cherryPickedCommitHashSet : set .New [string ](),
354
- showYouAreHereLabel : false ,
355
- now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
356
- expected : formatExpected (`
357
- hash1 pick commit1
358
- hash2 ◯ commit2
359
- hash3 ◯ commit3
360
- ` ),
361
- },
362
335
{
363
336
testName : "graph in divergence view - all commits visible" ,
364
337
commits : []* models.Commit {
@@ -376,7 +349,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
376
349
showGraph : true ,
377
350
bisectInfo : git_commands .NewNullBisectInfo (),
378
351
cherryPickedCommitHashSet : set .New [string ](),
379
- showYouAreHereLabel : false ,
380
352
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
381
353
expected : formatExpected (`
382
354
↓ hash1r ◯ commit1
@@ -406,7 +378,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
406
378
showGraph : true ,
407
379
bisectInfo : git_commands .NewNullBisectInfo (),
408
380
cherryPickedCommitHashSet : set .New [string ](),
409
- showYouAreHereLabel : false ,
410
381
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
411
382
expected : formatExpected (`
412
383
↓ hash3r ◯ │ commit3
@@ -434,7 +405,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
434
405
showGraph : true ,
435
406
bisectInfo : git_commands .NewNullBisectInfo (),
436
407
cherryPickedCommitHashSet : set .New [string ](),
437
- showYouAreHereLabel : false ,
438
408
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
439
409
expected : formatExpected (`
440
410
↓ hash1r ◯ commit1
@@ -461,7 +431,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
461
431
showGraph : true ,
462
432
bisectInfo : git_commands .NewNullBisectInfo (),
463
433
cherryPickedCommitHashSet : set .New [string ](),
464
- showYouAreHereLabel : false ,
465
434
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
466
435
expected : formatExpected (`
467
436
↑ hash2l ⏣─╮ commit2
@@ -487,7 +456,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
487
456
showGraph : true ,
488
457
bisectInfo : git_commands .NewNullBisectInfo (),
489
458
cherryPickedCommitHashSet : set .New [string ](),
490
- showYouAreHereLabel : false ,
491
459
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
492
460
expected : formatExpected (`
493
461
↓ hash1r ◯ commit1
@@ -508,7 +476,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
508
476
showGraph : true ,
509
477
bisectInfo : git_commands .NewNullBisectInfo (),
510
478
cherryPickedCommitHashSet : set .New [string ](),
511
- showYouAreHereLabel : false ,
512
479
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
513
480
expected : formatExpected (`
514
481
↑ hash1l ◯ commit1
@@ -530,7 +497,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
530
497
showGraph : true ,
531
498
bisectInfo : git_commands .NewNullBisectInfo (),
532
499
cherryPickedCommitHashSet : set .New [string ](),
533
- showYouAreHereLabel : false ,
534
500
now : time .Date (2020 , 1 , 1 , 0 , 0 , 0 , 0 , time .UTC ),
535
501
expected : formatExpected (`
536
502
↓ hash1r ◯ commit1
@@ -596,7 +562,6 @@ func TestGetCommitListDisplayStrings(t *testing.T) {
596
562
s .endIdx ,
597
563
s .showGraph ,
598
564
s .bisectInfo ,
599
- s .showYouAreHereLabel ,
600
565
)
601
566
602
567
renderedLines , _ := utils .RenderDisplayStrings (result , nil )
0 commit comments