summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Scheller <github@loowis.durge.org>2016-07-04 12:55:02 +0100
committerAndrew Scheller <github@loowis.durge.org>2016-07-04 12:55:02 +0100
commitf5ba0d6749c757ad86b767998f5a64a2109e86c5 (patch)
tree3a5c99cfae1d35ea8e3cfb09751c741af5e7b920
parent0958c4f7223dcb160baab9b84b83597b219f9d55 (diff)
downloadpyfilesystem-git-f5ba0d6749c757ad86b767998f5a64a2109e86c5.tar.gz
Fix FSImportHook tests on python3
-rw-r--r--fs/tests/test_importhook.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/tests/test_importhook.py b/fs/tests/test_importhook.py
index b04a86c..e0d1ad7 100644
--- a/fs/tests/test_importhook.py
+++ b/fs/tests/test_importhook.py
@@ -23,8 +23,8 @@ class TestFSImportHook(unittest.TestCase):
if isinstance(mph,FSImportHook):
sys.meta_path.remove(mph)
for ph in list(sys.path_hooks):
- if issubclass(ph,FSImportHook):
- sys.path_hooks.remove(mph)
+ if isinstance(ph, type) and issubclass(ph,FSImportHook):
+ sys.path_hooks.remove(ph)
for (k,v) in sys.modules.items():
if k.startswith("fsih_"):
del sys.modules[k]