diff options
author | Daniƫl van Noord <13665637+DanielNoord@users.noreply.github.com> | 2022-08-17 17:14:34 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-17 17:14:34 +0200 |
commit | a2c57ec06070b6d2485082e3a131a087f8d6d921 (patch) | |
tree | c0d01a231ee2c48772a4d9c84bcf855454bc74a5 /tests/test_check_parallel.py | |
parent | 39f0e30547f7d6de849c71ef6cb7fe1ec8b57ca0 (diff) | |
download | pylint-git-a2c57ec06070b6d2485082e3a131a087f8d6d921.tar.gz |
Refactor check() (#7288)
Diffstat (limited to 'tests/test_check_parallel.py')
-rw-r--r-- | tests/test_check_parallel.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/test_check_parallel.py b/tests/test_check_parallel.py index 259c236d4..3b6d82e04 100644 --- a/tests/test_check_parallel.py +++ b/tests/test_check_parallel.py @@ -467,8 +467,10 @@ class TestCheckParallel: # establish the baseline assert ( linter.config.jobs == 1 - ), "jobs>1 are ignored when calling _check_files" - linter._check_files(linter.get_ast, file_infos) + ), "jobs>1 are ignored when calling _lint_files" + ast_mapping = linter._get_asts(iter(file_infos), None) + with linter._astroid_module_checker() as check_astroid_module: + linter._lint_files(ast_mapping, check_astroid_module) assert linter.msg_status == 0, "We should not fail the lint" stats_single_proc = linter.stats else: @@ -534,8 +536,10 @@ class TestCheckParallel: # establish the baseline assert ( linter.config.jobs == 1 - ), "jobs>1 are ignored when calling _check_files" - linter._check_files(linter.get_ast, file_infos) + ), "jobs>1 are ignored when calling _lint_files" + ast_mapping = linter._get_asts(iter(file_infos), None) + with linter._astroid_module_checker() as check_astroid_module: + linter._lint_files(ast_mapping, check_astroid_module) stats_single_proc = linter.stats else: check_parallel( |