mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-04 20:26:53 +00:00
13 lines
464 B
Python
13 lines
464 B
Python
"""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')
|