Start tests for PluginManager

This commit is contained in:
Ian Cordasco 2016-01-19 23:01:07 -06:00
parent 56a75cc391
commit 6a72e36681

View file

@ -0,0 +1,13 @@
"""Tests for flake8.plugins.manager.PluginManager."""
import mock
from flake8.plugins import manager
@mock.patch('pkg_resources.iter_entry_points')
def test_calls_pkg_resources_on_instantiation(iter_entry_points):
"""Verify that we call iter_entry_points when we create a manager."""
iter_entry_points.return_value = []
manager.PluginManager(namespace='testing.pkg_resources')
iter_entry_points.assert_called_once_with('testing.pkg_resources')