mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-06 21:16:54 +00:00
move managing of off_by_default / enable_extensions to plugin loading
This commit is contained in:
parent
ff13916d74
commit
a8333e2bf2
12 changed files with 137 additions and 111 deletions
|
|
@ -90,7 +90,7 @@ def mock_file_checker_with_plugin(plugin_target):
|
|||
),
|
||||
),
|
||||
]
|
||||
plugins = finder.load_plugins(to_load, [])
|
||||
plugins = finder.load_plugins(to_load, [], set())
|
||||
|
||||
# Prevent it from reading lines from stdin or somewhere else
|
||||
with mock.patch(
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ def test_enable_local_plugin_from_config(local_config):
|
|||
cfg, cfg_dir = config.load_config(local_config, [], isolated=False)
|
||||
plugins = finder.find_plugins(cfg)
|
||||
plugin_paths = finder.find_local_plugin_paths(cfg, cfg_dir)
|
||||
loaded_plugins = finder.load_plugins(plugins, plugin_paths)
|
||||
loaded_plugins = finder.load_plugins(plugins, plugin_paths, set())
|
||||
|
||||
(custom_extension,) = (
|
||||
loaded
|
||||
|
|
@ -82,7 +82,8 @@ def test_local_plugin_can_add_option(local_config):
|
|||
|
||||
plugins = finder.find_plugins(cfg)
|
||||
plugin_paths = finder.find_local_plugin_paths(cfg, cfg_dir)
|
||||
loaded_plugins = finder.load_plugins(plugins, plugin_paths)
|
||||
enabled = finder.parse_enabled(cfg, stage1_args.enable_extensions)
|
||||
loaded_plugins = finder.load_plugins(plugins, plugin_paths, enabled)
|
||||
|
||||
option_manager = OptionManager(
|
||||
version="123",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue