summaryrefslogtreecommitdiffstats
path: root/tests/common.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/common.py')
-rw-r--r--tests/common.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/tests/common.py b/tests/common.py
index fe7940f..d41b9f2 100644
--- a/tests/common.py
+++ b/tests/common.py
@@ -42,11 +42,7 @@ def importModule(module, directory, name=None):
except ImportError, e:
raise SystemExit('%s could not be imported: %s' % (origName, e))
- if hasattr(obj, '__file__'):
- location = obj.__file__
- else:
- package = __import__(fromlist)
- location = os.path.join(package.__file__, name)
+ location = obj.__file__
current = os.getcwd()
expected = os.path.abspath(os.path.join(current, location))