convert: split start_multi_file_filter() into two separate functions
[gitweb.git] / t / t4202-log.sh
index 1ccbd5948a735f692469e181933c97e8632404b4..48b55bfd274a7adffe18af13489a54a7d92707a4 100755 (executable)
@@ -359,6 +359,28 @@ test_expect_success 'log --graph --line-prefix="| | | " with merge' '
        test_cmp expect actual
 '
 
+cat > expect.colors <<\EOF
+*   Merge branch 'side'
+<BLUE>|<RESET><CYAN>\<RESET>
+<BLUE>|<RESET> * side-2
+<BLUE>|<RESET> * side-1
+* <CYAN>|<RESET> Second
+* <CYAN>|<RESET> sixth
+* <CYAN>|<RESET> fifth
+* <CYAN>|<RESET> fourth
+<CYAN>|<RESET><CYAN>/<RESET>
+* third
+* second
+* initial
+EOF
+
+test_expect_success 'log --graph with merge with log.graphColors' '
+       test_config log.graphColors " blue,invalid-color, cyan, red  , " &&
+       git log --color=always --graph --date-order --pretty=tformat:%s |
+               test_decode_color | sed "s/ *\$//" >actual &&
+       test_cmp expect.colors actual
+'
+
 test_expect_success 'log --raw --graph -m with merge' '
        git log --raw --graph --oneline -m master | head -n 500 >actual &&
        grep "initial" actual
@@ -1190,6 +1212,54 @@ test_expect_success 'log --line-prefix="*** " --graph with diff and stats' '
        test_i18ncmp expect actual.sanitized
 '
 
+cat >expect <<-\EOF
+* reach
+|
+| A    reach.t
+* Merge branch 'tangle'
+*   Merge branch 'side'
+|\
+| * side-2
+|
+|   A  2
+* Second
+|
+| A    one
+* sixth
+
+  D    a/two
+EOF
+
+test_expect_success 'log --graph with --name-status' '
+       git log --graph --format=%s --name-status tangle..reach >actual &&
+       sanitize_output <actual >actual.sanitized &&
+       test_cmp expect actual.sanitized
+'
+
+cat >expect <<-\EOF
+* reach
+|
+| reach.t
+* Merge branch 'tangle'
+*   Merge branch 'side'
+|\
+| * side-2
+|
+|   2
+* Second
+|
+| one
+* sixth
+
+  a/two
+EOF
+
+test_expect_success 'log --graph with --name-only' '
+       git log --graph --format=%s --name-only tangle..reach >actual &&
+       sanitize_output <actual >actual.sanitized &&
+       test_cmp expect actual.sanitized
+'
+
 test_expect_success 'dotdot is a parent directory' '
        mkdir -p a/b &&
        ( echo sixth && echo fifth ) >expect &&