-------------------------------------------------------------------------
| 90 | |
| 91 | //------------------------------------------------------------------------- |
| 92 | void WriteSourceRoots( |
| 93 | const Plugin::CoverageData& coverageData, |
| 94 | property_tree::wptree& coverageTree) |
| 95 | { |
| 96 | std::unordered_set<std::wstring> rootPaths; |
| 97 | |
| 98 | for (const auto& module : coverageData.GetModules()) |
| 99 | { |
| 100 | for (const auto& file : module->GetFiles()) |
| 101 | { |
| 102 | const auto& path = file->GetPath(); |
| 103 | rootPaths.insert(path.root_name().wstring()); |
| 104 | } |
| 105 | } |
| 106 | |
| 107 | auto& sourcesTree = AddChild(coverageTree, L"sources"); |
| 108 | |
| 109 | for (const auto& rootPath : rootPaths) |
| 110 | sourcesTree.add(L"source", rootPath); |
| 111 | } |
| 112 | |
| 113 | //------------------------------------------------------------------------- |
| 114 | void SetCoverageAttributes(property_tree::wptree& coverageTree, |