[PATCH] color: add test for record support

Brodie Rao dackze at gmail.com
Fri Oct 9 02:58:25 CDT 2009


# HG changeset patch
# User Brodie Rao <me+hg at dackz.net>
# Date 1255074804 14400
# Node ID bfc74e0980069dd437b5315cf73c3db790c328e9
# Parent  7e03423def3ca43706fb5a9a8951ba10cdb75ba0
color: add test for record support

diff --git a/tests/test-diff-color b/tests/test-diff-color
--- a/tests/test-diff-color
+++ b/tests/test-diff-color
@@ -33,4 +33,18 @@ echo '% default context'
 hg diff --nodates --color=always
 
 echo '% --unified=2'
-hg diff --nodates -U 2  --color=always
\ No newline at end of file
+hg diff --nodates -U 2  --color=always
+
+echo "record=" >> $HGRCPATH
+echo "[ui]" >> $HGRCPATH
+echo "interactive=true" >> $HGRCPATH
+echo "[diff]" >> $HGRCPATH
+echo "git=True" >> $HGRCPATH
+
+echo % record
+chmod 0755 a
+hg record --color=always -m moda a <<EOF
+y
+y
+EOF
+echo
diff --git a/tests/test-diff-color.out b/tests/test-diff-color.out
--- a/tests/test-diff-color.out
+++ b/tests/test-diff-color.out
@@ -23,3 +23,18 @@ adding a
 +dd
  a
  a
+% record
+diff --git a/a b/a
+old mode 100644
+new mode 100755
+1 hunks, 2 lines changed
+examine changes to 'a'? [Ynsfdaq?]  @@ -2,7 +2,7 @@
+ c
+ a
+ a
+-b
++dd
+ a
+ a
+ c
+record this change to 'a'? [Ynsfdaq?]  


More information about the Mercurial-devel mailing list