diff options
| author | Eric N. Vander Weele <ericvw@gmail.com> | 2019-10-12 12:30:53 +0200 |
|---|---|---|
| committer | Eric N. Vander Weele <ericvw@gmail.com> | 2019-10-12 14:25:50 +0100 |
| commit | 601702294270dd34aa5f7f19abe1dfead911fee9 (patch) | |
| tree | a83a67a6f7e9a6309dd6e99d741b6db864604c9d /tests | |
| parent | 0359533fca164ef21c40c8074fbd3899316b8f91 (diff) | |
| download | flake8-601702294270dd34aa5f7f19abe1dfead911fee9.tar.gz | |
options: Remove parsing `--verbose` from the configuration file
The `--verbose` option is only used by `flake8`, itself,` when parsing
and handling preliminary options. After parsing and merging options
from the configuration file, there is no other behavioral impact to the
core of `flake8`. In other words, setting `verbose = ...` in a
configuration file doesn't change the logging verbosity.
While the `FileProcessor` does expose a `verbose` attribute, obtained
from the parsed options, the verbosity of the core of `flake8` should be
consistent with how a plugin may respond to the attribute's value.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/fixtures/config_files/cli-specified.ini | 1 | ||||
| -rw-r--r-- | tests/unit/test_merged_config_parser.py | 9 |
2 files changed, 0 insertions, 10 deletions
diff --git a/tests/fixtures/config_files/cli-specified.ini b/tests/fixtures/config_files/cli-specified.ini index c67e1e9..75c5f23 100644 --- a/tests/fixtures/config_files/cli-specified.ini +++ b/tests/fixtures/config_files/cli-specified.ini @@ -7,5 +7,4 @@ exclude = foo/, bar/, bogus/ -verbose = 2 quiet = 1 diff --git a/tests/unit/test_merged_config_parser.py b/tests/unit/test_merged_config_parser.py index 1112a0d..56ee893 100644 --- a/tests/unit/test_merged_config_parser.py +++ b/tests/unit/test_merged_config_parser.py @@ -27,8 +27,6 @@ def test_parse_cli_config(optmanager, config_finder): normalize_paths=True) optmanager.add_option('--ignore', parse_from_config=True, comma_separated_list=True) - optmanager.add_option('--verbose', parse_from_config=True, - action='count') optmanager.add_option('--quiet', parse_from_config=True, action='count') parser = config.MergedConfigParser(optmanager, config_finder) @@ -43,7 +41,6 @@ def test_parse_cli_config(optmanager, config_finder): os.path.abspath('bar/'), os.path.abspath('bogus/'), ], - 'verbose': 2, 'quiet': 1, } @@ -68,8 +65,6 @@ def test_parse_user_config(optmanager, config_finder): normalize_paths=True) optmanager.add_option('--ignore', parse_from_config=True, comma_separated_list=True) - optmanager.add_option('--verbose', parse_from_config=True, - action='count') optmanager.add_option('--quiet', parse_from_config=True, action='count') parser = config.MergedConfigParser(optmanager, config_finder) @@ -85,7 +80,6 @@ def test_parse_user_config(optmanager, config_finder): os.path.abspath('bar/'), os.path.abspath('bogus/'), ], - 'verbose': 2, 'quiet': 1, } @@ -97,8 +91,6 @@ def test_parse_local_config(optmanager, config_finder): normalize_paths=True) optmanager.add_option('--ignore', parse_from_config=True, comma_separated_list=True) - optmanager.add_option('--verbose', parse_from_config=True, - action='count') optmanager.add_option('--quiet', parse_from_config=True, action='count') parser = config.MergedConfigParser(optmanager, config_finder) @@ -116,7 +108,6 @@ def test_parse_local_config(optmanager, config_finder): os.path.abspath('bar/'), os.path.abspath('bogus/'), ], - 'verbose': 2, 'quiet': 1, } |
