SF bug #804115: bad argument handling(unittest.py)

This commit is contained in:
Raymond Hettinger 2003-09-13 02:58:00 +00:00
parent 42a61ed277
commit 91dd19db6f

View File

@ -560,8 +560,8 @@ class _WritelnDecorator:
def __getattr__(self, attr):
return getattr(self.stream,attr)
def writeln(self, *args):
if args: self.write(*args)
def writeln(self, arg=None):
if arg: self.write(arg)
self.write('\n') # text-mode streams translate to \r\n if needed