tests/test-diff-color.t
branchstable
changeset 38752 8623a6c96998
parent 38660 b07b691d2667
child 39091 ddc1da134772
equal deleted inserted replaced
38751:71d6886d27cf 38752:8623a6c96998
    52    c
    52    c
    53 
    53 
    54 trailing whitespace
    54 trailing whitespace
    55 
    55 
    56   $ cp a a.orig
    56   $ cp a a.orig
    57   $ sed 's/^dd$/dd \r/' a >a.new
    57   >>> with open('a', 'rb') as f:
    58   $ mv a.new a
    58   ...     data = f.read()
       
    59   >>> with open('a', 'wb') as f:
       
    60   ...     f.write(data.replace('dd', 'dd \r'))
    59   $ hg diff --nodates
    61   $ hg diff --nodates
    60   \x1b[0;1mdiff -r cf9f4ba66af2 a\x1b[0m (esc)
    62   \x1b[0;1mdiff -r cf9f4ba66af2 a\x1b[0m (esc)
    61   \x1b[0;31;1m--- a/a\x1b[0m (esc)
    63   \x1b[0;31;1m--- a/a\x1b[0m (esc)
    62   \x1b[0;32;1m+++ b/a\x1b[0m (esc)
    64   \x1b[0;32;1m+++ b/a\x1b[0m (esc)
    63   \x1b[0;35m@@ -2,7 +2,7 @@\x1b[0m (esc)
    65   \x1b[0;35m@@ -2,7 +2,7 @@\x1b[0m (esc)