diff --git a/codespell_lib/tests/test_basic.py b/codespell_lib/tests/test_basic.py index f88f3de672..a9401b2a74 100644 --- a/codespell_lib/tests/test_basic.py +++ b/codespell_lib/tests/test_basic.py @@ -5,6 +5,7 @@ import re import subprocess import sys +from io import StringIO from shutil import copyfile import pytest @@ -908,10 +909,6 @@ def test_config_toml(tmp_path, capsys, kind): @contextlib.contextmanager def FakeStdin(text): - if sys.version[0] == '2': - from StringIO import StringIO - else: - from io import StringIO oldin = sys.stdin try: in_ = StringIO(text)