From a85860db67b4e76f7788f15726393206df2da2be Mon Sep 17 00:00:00 2001 From: decalage2 Date: Tue, 5 Nov 2019 22:34:24 +0100 Subject: [PATCH] tests: fixed exception in test_encoding_handler.py --- tests/common/test_encoding_handler.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/common/test_encoding_handler.py b/tests/common/test_encoding_handler.py index 0c0bc30..42d4565 100644 --- a/tests/common/test_encoding_handler.py +++ b/tests/common/test_encoding_handler.py @@ -152,8 +152,9 @@ def run_read(filename): raise ValueError('Reader is not closed outside context') if reader.name != filename: raise ValueError('Wrong filename {} after context'.format(reader.name)) - if reader.isatty(): - raise ValueError('Reader has become a tty!') + # the following test raises an exception because reader is closed, so isatty cannot be called: + # if reader.isatty(): + # raise ValueError('Reader has become a tty!') # compare text if sys.version_info.major <= 2: # in python2 get encoded byte string -- libgit2 0.21.4