summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2006-04-26 06:26:12 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2006-04-26 06:26:12 (GMT)
commit9cc3b1ccef8f348ebfc36a13ec54e78423e9b4ff (patch)
tree4632e594f860efba5beba3ab6cd1302eb711af66
parent57a0361a9e70268fd3299482284bbcf71ea7642f (diff)
downloadcpython-9cc3b1ccef8f348ebfc36a13ec54e78423e9b4ff.zip
cpython-9cc3b1ccef8f348ebfc36a13ec54e78423e9b4ff.tar.gz
cpython-9cc3b1ccef8f348ebfc36a13ec54e78423e9b4ff.tar.bz2
Fix this test on Solaris. There can be embedded \r, so don't just replace
the one at the end.
-rw-r--r--Lib/test/test_pty.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_pty.py b/Lib/test/test_pty.py
index 7b1f460..59e5162 100644
--- a/Lib/test/test_pty.py
+++ b/Lib/test/test_pty.py
@@ -24,11 +24,11 @@ def normalize_output(data):
# OSF/1 (Tru64) apparently turns \n into \r\r\n.
if data.endswith('\r\r\n'):
- return data[:-3] + '\n'
+ return data.replace('\r\r\n', '\n')
# IRIX apparently turns \n into \r\n.
if data.endswith('\r\n'):
- return data[:-2] + '\n'
+ return data.replace('\r\n', '\n')
return data