Mercurial > python-cmd2
changeset 303:c3b9b2256dd6
tweaking transcript test newlines
author | catherine@dellzilla |
---|---|
date | Wed, 27 Jan 2010 10:05:11 -0500 |
parents | b4b22dd087dc |
children | 8c96f829ba1b |
files | cmd2.py |
diffstat | 1 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/cmd2.py Tue Jan 26 18:11:12 2010 -0500 +++ b/cmd2.py Wed Jan 27 10:05:11 2010 -0500 @@ -1237,15 +1237,15 @@ def _test_transcript(self, fname, transcript): lineNum = 0 try: - line = transcript.next() + line = transcript.next().strip() while True: while not line.startswith(self.cmdapp.prompt): - line = transcript.next() + line = transcript.next().strip() command = [line[len(self.cmdapp.prompt):]] - line = transcript.next() + line = transcript.next().strip() while line.startswith(self.cmdapp.continuation_prompt): command.append(line[len(self.cmdapp.continuation_prompt):]) - line = transcript.next() + line = transcript.next().strip() command = ''.join(command) self.cmdapp.onecmd(command) result = self.outputTrap.read().strip()