summaryrefslogtreecommitdiff
path: root/test/units/plugins/test_plugins.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/units/plugins/test_plugins.py')
-rw-r--r--test/units/plugins/test_plugins.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/units/plugins/test_plugins.py b/test/units/plugins/test_plugins.py
index be123b15..ba2ad2b6 100644
--- a/test/units/plugins/test_plugins.py
+++ b/test/units/plugins/test_plugins.py
@@ -46,14 +46,14 @@ class TestErrors(unittest.TestCase):
# python library, and then uses the __file__ attribute of
# the result for that to get the library path, so we mock
# that here and patch the builtin to use our mocked result
- foo = MagicMock()
- bar = MagicMock()
+ foo_pkg = MagicMock()
+ bar_pkg = MagicMock()
bam = MagicMock()
bam.__file__ = '/path/to/my/foo/bar/bam/__init__.py'
- bar.bam = bam
- foo.return_value.bar = bar
+ bar_pkg.bam = bam
+ foo_pkg.return_value.bar = bar_pkg
pl = PluginLoader('test', 'foo.bar.bam', 'test', 'test_plugin')
- with patch('builtins.__import__', foo):
+ with patch('builtins.__import__', foo_pkg):
self.assertEqual(pl._get_package_paths(), ['/path/to/my/foo/bar/bam'])
def test_plugins__get_paths(self):