diff --git a/tests/test_types.py b/tests/test_types.py index f946a8b8..4d0f0f70 100644 --- a/tests/test_types.py +++ b/tests/test_types.py @@ -41,7 +41,7 @@ class TestCorrectedCommand(object): settings.update(override_settings) CorrectedCommand(script, None, 1000).run(Command(script, '')) out, _ = capsys.readouterr() - assert out[:-1] == printed + assert out == printed class TestRule(object): diff --git a/thefuck/types.py b/thefuck/types.py index 5afcf2c4..5d8c2cc7 100644 --- a/thefuck/types.py +++ b/thefuck/types.py @@ -255,4 +255,4 @@ class CorrectedCommand(object): logs.debug(u'PYTHONIOENCODING: {}'.format( os.environ.get('PYTHONIOENCODING', '!!not-set!!'))) - print(self._get_script()) + sys.stdout.write(self._get_script())