test/cli: ensure that there is unmatchedSuppression warning
This commit is contained in:
parent
e24ce5b3ba
commit
1fdae247b3
|
@ -1,2 +1,5 @@
|
||||||
#include <1.h>
|
#include <1.h>
|
||||||
|
|
||||||
|
// cppcheck-suppress some_warning_id ; there should be a unmatchedSuppression warning about this
|
||||||
|
x;
|
||||||
|
|
||||||
|
|
|
@ -15,3 +15,7 @@ def test2():
|
||||||
assert ret == 0
|
assert ret == 0
|
||||||
assert len(stderr) > 0
|
assert len(stderr) > 0
|
||||||
|
|
||||||
|
def test_unmatched_suppression():
|
||||||
|
ret, stdout, stderr = cppcheck(['--inline-suppr', '--enable=information', '--error-exitcode=1', 'proj-inline-suppress'])
|
||||||
|
assert ret == 1
|
||||||
|
assert 'Unmatched suppression: some_warning_id' in stderr
|
||||||
|
|
Loading…
Reference in New Issue