Mercurial > hg
changeset 3789:734b1d6ba3dc
Use python instead of shell printf with \x sequences for test-encoding.
Needed e.g. to be compatible with Solaris.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Tue, 05 Dec 2006 11:23:37 +0100 |
parents | 18c93649f563 |
children | f183c18568df 4670470b97bd |
files | tests/test-encoding |
diffstat | 1 files changed, 5 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-encoding Mon Dec 04 17:43:37 2006 -0600 +++ b/tests/test-encoding Tue Dec 05 11:23:37 2006 +0100 @@ -7,9 +7,11 @@ hg unbundle $TESTDIR/legacy-encoding.hg hg co -printf "latin-1 e' encoded: \xe9" > latin-1 -printf "utf-8 e' encoded: \xc3\xa9" > utf-8 -printf "\xe9" > latin-1-tag +python << EOF +f = file('latin-1', 'w'); f.write("latin-1 e' encoded: \xe9"); f.close() +f = file('utf-8', 'w'); f.write("utf-8 e' encoded: \xc3\xa9"); f.close() +f = file('latin-1-tag', 'w'); f.write("\xe9"); f.close() +EOF echo % should fail with encoding error echo "plain old ascii" > a