(tmpdir)
| 162 | |
| 163 | |
| 164 | def test_slnx_project_file_not_found(tmpdir): |
| 165 | content = '<?xml version="1.0" encoding="UTF-8"?>\r\n' \ |
| 166 | "<Solution>\r\n" \ |
| 167 | " <Configurations>\r\n" \ |
| 168 | ' <Platform Name="x64" />\r\n' \ |
| 169 | ' <Platform Name="x86" />\r\n' \ |
| 170 | " </Configurations>\r\n" \ |
| 171 | ' <Project Path="test.vcxproj" />\r\n' \ |
| 172 | "</Solution>\r\n" |
| 173 | |
| 174 | expected = "Visual Studio project file is not a valid XML - XML_ERROR_FILE_NOT_FOUND\n" \ |
| 175 | "cppcheck: error: failed to load '{}' from Visual Studio solution".format(os.path.join(tmpdir, "test.vcxproj")) |
| 176 | if sys.platform == "win32": |
| 177 | expected = expected.replace('\\', '/') |
| 178 | |
| 179 | __test_project_error(tmpdir, "slnx", content, expected) |
| 180 | |
| 181 | |
| 182 | def test_vcxproj_no_xml_root(tmpdir): |
nothing calls this directly
no test coverage detected