diff tests/test-revert-interactive.t @ 24434:f169405c03ab

test-interactive: use stable EOL in various file generating routines The seq.py and shell echo redirected to a file ends up with platform specific EOL, which throws off the hash when the file is committed to the test repo on Windows. The other option is to glob the hashes, but the ability to see if they have changed might point out problems that would otherwise be missed.
author Matt Harbison <matt_harbison@yahoo.com>
date Sat, 21 Mar 2015 11:56:43 -0400
parents 93d3e1a8bfb0
children 06cbff4674a3
line wrap: on
line diff
--- a/tests/test-revert-interactive.t	Tue Mar 17 15:46:36 2015 -0700
+++ b/tests/test-revert-interactive.t	Sat Mar 21 11:56:43 2015 -0400
@@ -21,13 +21,17 @@
   $ mkdir -p a/folder1 a/folder2
   $ cd a
   $ hg init
-  $ python $TESTDIR/seq.py 1 5 > f ; hg add f ; hg commit -m "adding f"
+  >>> open('f', 'wb').write("1\n2\n3\n4\n5\n")
+  $ hg add f ; hg commit -m "adding f"
   $ cat f > folder1/g ; hg add folder1/g ; hg commit -m "adding folder1/g"
   $ cat f > folder2/h ; hg add folder2/h ; hg commit -m "adding folder2/h"
   $ cat f > folder1/i ; hg add folder1/i ; hg commit -m "adding folder1/i"
-  $ echo "a" > f ; python $TESTDIR/seq.py 1 5 >> f ; echo "b" >> f ; hg commit -m "modifying f"
-  $ echo "c" > folder1/g ; python $TESTDIR/seq.py 1 5 >> folder1/g ; echo "d" >> folder1/g ; hg commit -m "modifying folder1/g"
-  $ echo "e" > folder2/h ; python $TESTDIR/seq.py 1 5 >> folder2/h ; echo "f" >> folder2/h ; hg commit -m "modifying folder2/h"
+  >>> open('f', 'wb').write("a\n1\n2\n3\n4\n5\nb\n")
+  $ hg commit -m "modifying f"
+  >>> open('folder1/g', 'wb').write("c\n1\n2\n3\n4\n5\nd\n")
+  $ hg commit -m "modifying folder1/g"
+  >>> open('folder2/h', 'wb').write("e\n1\n2\n3\n4\n5\nf\n")
+  $ hg commit -m "modifying folder2/h"
   $ hg tip
   changeset:   6:59dd6e4ab63a
   tag:         tip