diff --git a/tests/misra/test_mutation.py b/tests/misra/test_mutation.py index c804135b817..c82456e6bbf 100755 --- a/tests/misra/test_mutation.py +++ b/tests/misra/test_mutation.py @@ -70,6 +70,9 @@ @pytest.mark.parametrize("fn, patch, should_fail", mutations) def test_misra_mutation(fn, patch, should_fail): + # Remove all files generated by cppcheck to speed tree copying + [os.remove(f) for f in glob.glob(f"{ROOT}/**/*", recursive=True) if f.endswith(('.dump', '.ctu-info'))] + with tempfile.TemporaryDirectory() as tmp: shutil.copytree(ROOT, tmp, dirs_exist_ok=True)