From e7fc9db8c2dbcdd85df2a36c790e7aac6f48baee Mon Sep 17 00:00:00 2001 From: dzid26 Date: Thu, 13 Jun 2024 03:13:38 +0100 Subject: [PATCH] rename test_misra.sh to prevent execution by Pytest --- .github/workflows/test.yaml | 2 +- .gitignore | 4 ++-- tests/misra/{test_misra.sh => cppcheck_misra_test.sh} | 0 tests/misra/test_mutation.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) rename tests/misra/{test_misra.sh => cppcheck_misra_test.sh} (100%) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index fe0b0c1b29..a98709aa5f 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -98,7 +98,7 @@ jobs: run: ${{ env.RUN }} "scons -j$(nproc)" - name: Run MISRA C:2012 analysis timeout-minutes: 1 - run: ${{ env.RUN }} "cd tests/misra && ./test_misra.sh" + run: ${{ env.RUN }} "cd tests/misra && ./cppcheck_misra_test.sh" - name: MISRA mutation tests timeout-minutes: 7 run: ${{ env.RUN }} "cd tests/misra && pytest -n8 test_mutation.py" diff --git a/.gitignore b/.gitignore index 2dfa094768..8975cdf875 100644 --- a/.gitignore +++ b/.gitignore @@ -6,7 +6,6 @@ *.so *.os *.d -*.dump a.out *~ .#* @@ -20,8 +19,9 @@ nosetests.xml .mypy_cache/ .sconsign.dblite -# CTU info files generated by Cppcheck +# files generated by Cppcheck *.*.ctu-info +*.*.dump # safety coverage-related files *.gcda diff --git a/tests/misra/test_misra.sh b/tests/misra/cppcheck_misra_test.sh similarity index 100% rename from tests/misra/test_misra.sh rename to tests/misra/cppcheck_misra_test.sh diff --git a/tests/misra/test_mutation.py b/tests/misra/test_mutation.py index da6aa85bde..e9f24ddde5 100755 --- a/tests/misra/test_mutation.py +++ b/tests/misra/test_mutation.py @@ -81,6 +81,6 @@ def test_misra_mutation(fn, patch, should_fail, tmp_path): assert r == 0 # run test - r = subprocess.run("SKIP_TABLES_DIFF=1 tests/misra/test_misra.sh", cwd=tmp_path, shell=True) + r = subprocess.run("SKIP_TABLES_DIFF=1 tests/misra/cppcheck_misra_test.sh", cwd=tmp_path, shell=True) failed = r.returncode != 0 assert failed == should_fail