We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 863f282 commit c1fb2f3Copy full SHA for c1fb2f3
testing/.clang-tidy
@@ -2,7 +2,6 @@
2
Checks: 'clang-diagnostic-*,clang-analyzer-*,-*,performance-*,bugprone-*,clang-analyzer-*,mpi-*,misc-*,readability-*'
3
WarningsAsErrors: ''
4
HeaderFilterRegex: ''
5
-AnalyzeTemporaryDtors: false
6
FormatStyle: 'file'
7
CheckOptions:
8
- key: bugprone-argument-comment.CommentBoolLiterals
testing/pre-commit-config-version.yaml
@@ -6,3 +6,31 @@ repos:
args: [--style=file, --version=16] # to load .clang-format
- id: clang-tidy
args: [--checks=.clang-tidy, --version=16] # path/to/.clang-tidy
9
+ - repo: .
10
+ rev: HEAD
11
+ hooks:
12
+ - id: clang-format
13
+ args: [--style=file, --version=17]
14
+ - id: clang-tidy
15
+ args: [--checks=.clang-tidy, --version=17]
16
17
18
19
20
+ args: [--style=file, --version=18]
21
22
+ args: [--checks=.clang-tidy, --version=18]
23
24
25
26
27
+ args: [--style=file, --version=19]
28
29
+ args: [--checks=.clang-tidy, --version=19]
30
31
32
33
34
+ args: [--style=file, --version=20]
35
36
+ args: [--checks=.clang-tidy, --version=20]
testing/run.sh
@@ -9,7 +9,9 @@ done
failed_cases=`grep -c "Failed" result.txt`
-if [ $failed_cases -eq 4 ]; then
+echo $failed_cases " cases failed."
+
+if [ $failed_cases -eq 9 ]; then
echo "=============================="
echo "Test cpp-linter-hooks success."
tests/test_clang_format.py
@@ -8,6 +8,10 @@
('args', 'expected_retval'), (
(['--style=Google'], (0, "")),
(['--style=Google', '--version=16'], (0, "")),
+ (['--style=Google', '--version=17'], (0, "")),
+ (['--style=Google', '--version=18'], (0, "")),
+ (['--style=Google', '--version=19'], (0, "")),
+ (['--style=Google', '--version=20'], (0, "")),
),
)
def test_run_clang_format_valid(args, expected_retval, tmp_path):
@@ -23,6 +27,10 @@ def test_run_clang_format_valid(args, expected_retval, tmp_path):
(['--style=Google',], 1),
(['--style=Google', '--version=16'], 1),
+ (['--style=Google', '--version=17'], 1),
+ (['--style=Google', '--version=18'], 1),
+ (['--style=Google', '--version=19'], 1),
+ (['--style=Google', '--version=20'], 1),
def test_run_clang_format_invalid(args, expected_retval, tmp_path):
tests/test_clang_tidy.py
@@ -16,6 +16,10 @@ def generate_compilation_database():
(['--checks="boost-*"'], 1),
(['--checks="boost-*"', '--version=16'], 1),
+ (['--checks="boost-*"', '--version=17'], 1),
+ (['--checks="boost-*"', '--version=18'], 1),
+ (['--checks="boost-*"', '--version=19'], 1),
+ (['--checks="boost-*"', '--version=20'], 1),
def test_run_clang_tidy_valid(args, expected_retval):
@@ -31,6 +35,10 @@ def test_run_clang_tidy_valid(args, expected_retval):
37
38
39
40
41
42
43
44
def test_run_clang_tidy_invalid(args, expected_retval, tmp_path):
0 commit comments