cpp-linter 1.14.0__tar.gz → 1.14.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {cpp_linter-1.14.0/cpp_linter.egg-info → cpp_linter-1.14.1}/PKG-INFO +1 -1
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/_version.py +3 -3
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/rest_api/github_api.py +5 -7
- {cpp_linter-1.14.0 → cpp_linter-1.14.1/cpp_linter.egg-info}/PKG-INFO +1 -1
- cpp_linter-1.14.1/cpp_linter.egg-info/scm_version.json +8 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/list_changes/test_get_file_changes.py +57 -0
- cpp_linter-1.14.0/cpp_linter.egg-info/scm_version.json +0 -8
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.gitattributes +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/dependabot.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/analyze-workflows.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/codeql.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/docs.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/labeler.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/pre-commit.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/release-drafter.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/release.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/stale.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/workflows/tests.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.github/zizmor.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.gitignore +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.pre-commit-config.yaml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/.readthedocs.yaml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/CONTRIBUTING.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/LICENSE +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/README.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/codecov.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/__init__.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/clang_tools/__init__.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/clang_tools/clang_format.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/clang_tools/clang_tidy.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/clang_tools/patcher.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/cli.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/common_fs/__init__.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/common_fs/file_filter.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/git/__init__.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/git/git_str.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/loggers.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter/rest_api/__init__.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/SOURCES.txt +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/dependency_links.txt +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/entry_points.txt +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/not-zip-safe +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/requires.txt +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/scm_file_list.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cpp_linter.egg-info/top_level.txt +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/cspell.config.yml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.clang_format.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.clang_tidy.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.patcher.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.cli.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.common_fs.file_filter.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.common_fs.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.git.git_str.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.git.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.loggers.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.rest_api.github_api.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.rest_api.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/_static/extra_css.css +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/_static/favicon.ico +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/_static/logo.png +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/building_docs.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/conf.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/contributing.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/index.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/permissions.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/pr_review_caveats.rst +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/noxfile.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/pyproject.toml +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/setup.cfg +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/setup.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/.clang-format +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/.clang-tidy +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/opl/opl.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/opl/opl_sdl.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/pcsound/pcsound.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/pcsound/pcsound_sdl.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/src/i_musicpack.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/src/i_sdlmusic.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/src/i_sdlsound.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/src/i_sound.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/cache/src/net_sdl.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/expected-result_0.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/expected-result_1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/expected-result_2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/67715d6e2725322e6132e9ff99b9a2a3f3b10c83/patch.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/cache/src/hexen/info.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/cache/src/hexen/p_enemy.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/cache/src/hexen/p_local.h +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/expected-result_0.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/expected-result_1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/expected-result_2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/chocolate-doom/chocolate-doom/71091562db5b0e7853d08ffa2f110af49cc3bc0d/patch.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/.clang-format +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/.clang-tidy +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/950ff0b690e1903797c303c5fc8d9f3b52f1d3c5/cache/tests/demo/demo.cpp +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/950ff0b690e1903797c303c5fc8d9f3b52f1d3c5/cache/tests/demo/demo.hpp +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/950ff0b690e1903797c303c5fc8d9f3b52f1d3c5/patch.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/test_git_lib.patch +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/.clang-format +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/.clang-tidy +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/fe82be345a5b654a76835a7aea5a804bd9ebff0a/expected-result_0.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/fe82be345a5b654a76835a7aea5a804bd9ebff0a/expected-result_1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/fe82be345a5b654a76835a7aea5a804bd9ebff0a/expected-result_2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/fe82be345a5b654a76835a7aea5a804bd9ebff0a/patch.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/.clang-format +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/.clang-tidy +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/662ad4cf90084063ea9c089b8de4aff0b8959d0e/cache/p_enemy.c +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/662ad4cf90084063ea9c089b8de4aff0b8959d0e/expected-result_0.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/662ad4cf90084063ea9c089b8de4aff0b8959d0e/expected-result_1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/662ad4cf90084063ea9c089b8de4aff0b8959d0e/expected-result_2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/shenxianpeng/test-repo/662ad4cf90084063ea9c089b8de4aff0b8959d0e/patch.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/test_auto_fix.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/test_database_path.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/test_tools_output.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/comments/pr_22.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/comments/pr_comments_pg1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/comments/pr_comments_pg2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/comments/push_8d68756375e0483c7ac2b4d6bbbece420dbbb495.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/comments/push_comments_8d68756375e0483c7ac2b4d6bbbece420dbbb495.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/comments/test_comments.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/demo/.clang-format +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/demo/.clang-tidy +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/demo/compile_flags.txt +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/demo/demo.cpp +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/demo/demo.hpp +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/ignored_paths/.gitmodules +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/ignored_paths/test_ignored_paths.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/list_changes/patch.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/list_changes/pull_request_files_pg1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/list_changes/pull_request_files_pg2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/list_changes/push_files_pg1.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/list_changes/push_files_pg2.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/.clang-format +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/.clang-tidy +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/pr_27.diff +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/pr_27.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/pr_review_comments.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/pr_reviews.json +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/reviews/test_pr_review.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/test_cli_args.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/test_comment_length.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/test_git_str.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/test_misc.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/test_parse_clang_tidy_stdout.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/test_rate_limits.py +0 -0
- {cpp_linter-1.14.0 → cpp_linter-1.14.1}/uv.lock +0 -0
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '1.14.
|
|
22
|
-
__version_tuple__ = version_tuple = (1, 14,
|
|
21
|
+
__version__ = version = '1.14.1'
|
|
22
|
+
__version_tuple__ = version_tuple = (1, 14, 1)
|
|
23
23
|
|
|
24
|
-
__commit_id__ = commit_id = '
|
|
24
|
+
__commit_id__ = commit_id = 'g44999fc08'
|
|
@@ -150,6 +150,8 @@ class GithubApiClient(RestApiClient):
|
|
|
150
150
|
f"Missing 'filename' key in file:\n{json.dumps(file, indent=2)}"
|
|
151
151
|
)
|
|
152
152
|
raise exc
|
|
153
|
+
if file.get("status", "") == "removed":
|
|
154
|
+
continue
|
|
153
155
|
if not file_filter.is_source_or_ignored(file_name):
|
|
154
156
|
continue
|
|
155
157
|
if lines_changed_only > 0 and cast(int, file.get("changes", 0)) == 0:
|
|
@@ -160,15 +162,11 @@ class GithubApiClient(RestApiClient):
|
|
|
160
162
|
if "patch" not in file:
|
|
161
163
|
if lines_changed_only > 0:
|
|
162
164
|
# diff info is needed for further operations
|
|
163
|
-
raise KeyError(
|
|
165
|
+
raise KeyError(
|
|
164
166
|
f"{file_name} has no patch info:\n{json.dumps(file, indent=2)}"
|
|
165
167
|
)
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
): # in case files-changed-only is true
|
|
169
|
-
# file was likely renamed without source changes
|
|
170
|
-
files.append(FileObj(file_name)) # scan entire file instead
|
|
171
|
-
continue
|
|
168
|
+
files.append(FileObj(file_name)) # scan entire file instead
|
|
169
|
+
continue
|
|
172
170
|
file_diff = (
|
|
173
171
|
f"diff --git a/{old_name} b/{file_name}\n"
|
|
174
172
|
+ f"--- a/{old_name}\n+++ b/{file_name}\n"
|
|
@@ -154,3 +154,60 @@ def test_get_changed_files(
|
|
|
154
154
|
if lines_changed_only == 0:
|
|
155
155
|
expected.append("include/test/tree.hpp")
|
|
156
156
|
assert file.name in expected
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
@pytest.mark.no_clang
|
|
160
|
+
@pytest.mark.parametrize("event_name", ["pull_request", "push"])
|
|
161
|
+
@pytest.mark.parametrize("status", ["added", "modified", "renamed", "removed"])
|
|
162
|
+
@pytest.mark.parametrize("lines_changed_only", [0, 1, 2])
|
|
163
|
+
def test_paginated_files_without_patches(
|
|
164
|
+
monkeypatch: pytest.MonkeyPatch,
|
|
165
|
+
event_name: str,
|
|
166
|
+
status: str,
|
|
167
|
+
lines_changed_only: int,
|
|
168
|
+
):
|
|
169
|
+
"""Missing patches permit whole-file linting, but not line filtering."""
|
|
170
|
+
monkeypatch.setenv("CI", "true")
|
|
171
|
+
monkeypatch.setenv("GITHUB_EVENT_PATH", "")
|
|
172
|
+
client = GithubApiClient()
|
|
173
|
+
client.event_name = event_name
|
|
174
|
+
client.api_url = TEST_API_URL
|
|
175
|
+
client.repo = TEST_REPO
|
|
176
|
+
client.sha = TEST_SHA
|
|
177
|
+
client.pull_request = TEST_PR
|
|
178
|
+
endpoint = f"{TEST_API_URL}/repos/{TEST_REPO}/commits/{TEST_SHA}"
|
|
179
|
+
if event_name == "pull_request":
|
|
180
|
+
endpoint = f"{TEST_API_URL}/repos/{TEST_REPO}/pulls/{TEST_PR}"
|
|
181
|
+
|
|
182
|
+
entries = [
|
|
183
|
+
{
|
|
184
|
+
"filename": "src/deleted.cpp",
|
|
185
|
+
"status": "removed",
|
|
186
|
+
"changes": 1,
|
|
187
|
+
"patch": "@@ -1 +0,0 @@\n-int removed;",
|
|
188
|
+
},
|
|
189
|
+
{"filename": "src/large.cpp", "status": status, "changes": 1000},
|
|
190
|
+
]
|
|
191
|
+
with requests_mock.Mocker() as mock:
|
|
192
|
+
mock.get(
|
|
193
|
+
endpoint,
|
|
194
|
+
request_headers={"Accept": "application/vnd.github.diff"},
|
|
195
|
+
status_code=406,
|
|
196
|
+
)
|
|
197
|
+
mock.get(
|
|
198
|
+
endpoint + ("/files" if event_name == "pull_request" else ""),
|
|
199
|
+
request_headers={"Accept": "application/vnd.github.raw+json"},
|
|
200
|
+
json=entries if event_name == "pull_request" else {"files": entries},
|
|
201
|
+
)
|
|
202
|
+
file_filter = FileFilter(extensions=["cpp"])
|
|
203
|
+
if lines_changed_only > 0 and status != "removed":
|
|
204
|
+
with pytest.raises(KeyError, match=r"src/large\.cpp has no patch info"):
|
|
205
|
+
client.get_list_of_changed_files(file_filter, lines_changed_only)
|
|
206
|
+
else:
|
|
207
|
+
files = client.get_list_of_changed_files(file_filter, lines_changed_only)
|
|
208
|
+
assert [file.name for file in files] == (
|
|
209
|
+
[] if status == "removed" else ["src/large.cpp"]
|
|
210
|
+
)
|
|
211
|
+
for file in files:
|
|
212
|
+
assert file.lines_added == []
|
|
213
|
+
assert file.diff_chunks == []
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.clang_format.rst
RENAMED
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.clang_tidy.rst
RENAMED
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.clang_tools.patcher.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.common_fs.file_filter.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/docs/API-Reference/cpp_linter.rest_api.github_api.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/cpp-linter/cpp-linter/.clang-tidy
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/.clang-format
RENAMED
|
File without changes
|
{cpp_linter-1.14.0 → cpp_linter-1.14.1}/tests/capture_tools_output/libvips/libvips/.clang-tidy
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|