diff --git a/pyproject.toml b/pyproject.toml index 1d8e828ce..311b17e9d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,6 +12,9 @@ extend_skip_glob = ["gdb-pt-dump/*"] branch = true parallel = true disable_warnings = ["module-not-imported"] -source = ["."] +source = ["${SRC_DIR-.}"] omit = ["ida_script.py"] data_file = ".cov/coverage" + +[tool.coverage.report] +omit = ["ida_script.py", "tests/*"] diff --git a/tests/gdb-tests/tests.sh b/tests/gdb-tests/tests.sh index 81c23343c..25ca86af5 100755 --- a/tests/gdb-tests/tests.sh +++ b/tests/gdb-tests/tests.sh @@ -68,7 +68,8 @@ tests_failed=0 for test_case in ${TESTS_LIST}; do gdb_args=(-ex 'py import coverage;coverage.process_startup()' --command $GDB_INIT_PATH --command pytests_launcher.py) - COVERAGE_FILE=$ROOT_DIR/.cov/coverage \ + SRC_DIR=$ROOT_DIR \ + COVERAGE_FILE=$ROOT_DIR/.cov/coverage \ COVERAGE_PROCESS_START=$COVERAGERC_PATH \ USE_PDB="${USE_PDB}" \ PWNDBG_LAUNCH_TEST="${test_case}" \