MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / test_local_path

Function test_local_path

test/cli/proj2_test.py:39–48  ·  view source on GitHub ↗
(tmp_path)

Source from the content-addressed store, hash-verified

37 assert stdout.find('Checking %s ...' % file2) >= 0
38
39def test_local_path(tmp_path):
40 proj_dir = tmp_path / 'proj2'
41 shutil.copytree(__proj_dir, proj_dir)
42 __create_compile_commands(proj_dir)
43 ret, stdout, _ = cppcheck(['--project=compile_commands.json'], cwd=proj_dir)
44 file1 = os.path.join('a', 'a.c')
45 file2 = os.path.join('b', 'b.c')
46 assert ret == 0, stdout
47 assert stdout.find('Checking %s ...' % file1) >= 0
48 assert stdout.find('Checking %s ...' % file2) >= 0
49
50def test_local_path_force(tmp_path):
51 proj_dir = tmp_path / 'proj2'

Callers

nothing calls this directly

Calls 4

cppcheckFunction · 0.90
joinMethod · 0.45
findMethod · 0.45

Tested by

no test coverage detected