tests: Remove unnecessary N* inline ignores and conform to PEP 8 names

This project uses the `pep8-naming` plugin for linting and the
non-conforming names that were ignored can be converted to be PEP 8
compliant without impacting behavior.
This commit is contained in:
Eric N. Vander Weele 2019-11-09 09:58:59 +08:00
parent e653ab8062
commit b05482147f
2 changed files with 20 additions and 20 deletions

View file

@ -7,13 +7,13 @@ from flake8 import checker
@mock.patch('flake8.processor.FileProcessor')
def test_run_ast_checks_handles_SyntaxErrors(FileProcessor): # noqa: N802,N803
def test_run_ast_checks_handles_syntax_errors(file_processor):
"""Stress our SyntaxError handling.
Related to: https://gitlab.com/pycqa/flake8/issues/237
"""
processor = mock.Mock(lines=[])
FileProcessor.return_value = processor
file_processor.return_value = processor
processor.build_ast.side_effect = SyntaxError('Failed to build ast',
('', 1, 5, 'foo(\n'))
file_checker = checker.FileChecker(__file__, checks={}, options=object())