Skip to content

Commit 6f3c931

Browse files
committed
include
1 parent 3200c53 commit 6f3c931

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

test/cli/test-helloworld.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ def __test_missing_include_system(use_j):
197197
args = '-j2 ' + args
198198

199199
_, _, stderr = cppcheck(args.split())
200-
assert stderr == 'nofile:0:0: information: Cppcheck cannot find all the include files (use --check-config for details) [missingIncludeSystem]\n\n'
200+
assert stderr == 'helloworld/main.c:1:0: information: Include file: <stdio.h> not found. Please note: Cppcheck does not need standard library headers to get proper results. [missingIncludeSystem]\n\n'
201201

202202
def test_missing_include_system():
203203
__test_missing_include_system(False)

test/cli/test-other.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def __test_missing_include(tmpdir, use_j):
1818
args = '-j2 ' + args
1919

2020
_, _, stderr = cppcheck(args.split())
21-
assert stderr == 'nofile:0:0: information: Cppcheck cannot find all the include files (use --check-config for details) [missingInclude]\n\n'
21+
assert stderr == '{}:2:0: information: Include file: "test.h" not found. [missingInclude]\n\n'.format(test_file)
2222

2323
def test_missing_include(tmpdir):
2424
__test_missing_include(tmpdir, False)
@@ -40,7 +40,7 @@ def __test_missing_include_check_config(tmpdir, use_j):
4040
args = '-j2 ' + args
4141

4242
_, _, stderr = cppcheck(args.split())
43-
assert stderr == '{}:2:0: information: Include file: "test.h" not found. [missingInclude]\n\n^\n'.format(test_file)
43+
assert stderr == '' # --check-config no longer reports the missing includes
4444

4545
def test_missing_include_check_config(tmpdir):
4646
__test_missing_include_check_config(tmpdir, False)

0 commit comments

Comments
 (0)