diff options
author | David Lord <davidism@gmail.com> | 2020-04-19 22:16:48 -0700 |
---|---|---|
committer | David Lord <davidism@gmail.com> | 2020-04-20 07:12:52 -0700 |
commit | 62f84aa3242d6d9f57243b941b013b2536ea3b9c (patch) | |
tree | 66ce32c33fd03caebd121272650eece5e68f2b3c /tests/test_imports.py | |
parent | 00883dd3d0a29f68f375cab5e21cef0669941aba (diff) | |
download | click-62f84aa3242d6d9f57243b941b013b2536ea3b9c.tar.gz |
remove more compat code
Diffstat (limited to 'tests/test_imports.py')
-rw-r--r-- | tests/test_imports.py | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/tests/test_imports.py b/tests/test_imports.py index b99d453..be8730f 100644 --- a/tests/test_imports.py +++ b/tests/test_imports.py @@ -6,10 +6,7 @@ from click._compat import WIN IMPORT_TEST = b"""\ -try: - import __builtin__ as builtins -except ImportError: - import builtins +import builtins found_imports = set() real_import = builtins.__import__ @@ -61,9 +58,7 @@ def test_light_imports(): [sys.executable, "-"], stdin=subprocess.PIPE, stdout=subprocess.PIPE ) rv = c.communicate(IMPORT_TEST)[0] - - if sys.version_info[0] != 2: - rv = rv.decode("utf-8") + rv = rv.decode("utf-8") imported = json.loads(rv) for module in imported: |