[2.7] bpo-31271: Fix an assertion failure in io.TextIOWrapper.write. (GH-3201) by miss-islington · Pull Request #3548 · python/cpython (original) (raw)

======================================================================

FAIL: test_illegal_encoder (test.test_io.CTextIOWrapperTest)

----------------------------------------------------------------------

Traceback (most recent call last):

  File "/home/travis/build/python/cpython/Lib/test/test_io.py", line 2675, in test_illegal_encoder

    self.assertRaises(TypeError, t.write, 'bar')

AssertionError: TypeError not raised

======================================================================

FAIL: test_illegal_encoder (test.test_io.PyTextIOWrapperTest)

----------------------------------------------------------------------

Traceback (most recent call last):

  File "/home/travis/build/python/cpython/Lib/test/test_io.py", line 2675, in test_illegal_encoder

    self.assertRaises(TypeError, t.write, 'bar')

AssertionError: TypeError not raised