(tmpdir, code)
| 55 | |
| 56 | |
| 57 | def __check_ast(tmpdir, code): |
| 58 | testfile = os.path.join(tmpdir, 'test.cpp') |
| 59 | with open(testfile, 'w+t') as f: |
| 60 | f.write(code) |
| 61 | ret1, stdout1, _ = cppcheck(['-q', '--clang', '--debug-ast', testfile]) |
| 62 | ret2, stdout2, _ = cppcheck(['-q', '--debug-ast', testfile]) |
| 63 | assert 0 == ret1, stdout1 |
| 64 | assert 0 == ret2, stdout1 |
| 65 | assert __get_debug_section('##AST', stdout1) == __get_debug_section('##AST', stdout2) |
| 66 | |
| 67 | |
| 68 |
no test coverage detected