aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/src/tests.plan.cpp
diff options
context:
space:
mode:
authorVictor Romero <romerosanchezv@gmail.com>2019-06-21 23:50:05 -0700
committerGitHub <noreply@github.com>2019-06-21 23:50:05 -0700
commitf3db66b403840b24ea2612d09cca30a5285f5ea3 (patch)
treeeb3504205b87fa7ae5b7ccdba4820469c9e856c0 /toolsrc/src/tests.plan.cpp
parentd1b4e88d3c1bd714069f10009c6f9cef172cc822 (diff)
downloadvcpkg-f3db66b403840b24ea2612d09cca30a5285f5ea3.tar.gz
vcpkg-f3db66b403840b24ea2612d09cca30a5285f5ea3.zip
Ports Overlay partial implementation (#6981)
* Ports Overlay feature spec * Ports Overlay implementation * [--overlay-ports] Refactor handling of additional paths * Code cleanup * [--overlay-ports] Add help * [depend-info] Support --overlay-ports * Add method to load all ports using PathsPortFileProvider * Make PortFileProvider::load_all_control_files() const * Remove unused code * [vcpkg] Avoid double-load of source control file between Build::perform_and_exit and Build::perform_and_exit_ex * [vcpkg] Clang format * [vcpkg] Fixup build failure introduced in b069ceb2f231 * Report errors from Paragraphs::try_load_port()
Diffstat (limited to 'toolsrc/src/tests.plan.cpp')
-rw-r--r--toolsrc/src/tests.plan.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/toolsrc/src/tests.plan.cpp b/toolsrc/src/tests.plan.cpp
index 238aa7032..ab24266b4 100644
--- a/toolsrc/src/tests.plan.cpp
+++ b/toolsrc/src/tests.plan.cpp
@@ -47,7 +47,8 @@ namespace UnitTest1
Assert::AreEqual(plan.spec.triplet().to_string().c_str(), triplet.to_string().c_str());
- Assert::AreEqual(pkg_name.c_str(), plan.source_control_file.get()->core_paragraph->name.c_str());
+ auto* scfl = plan.source_control_file_location.get();
+ Assert::AreEqual(pkg_name.c_str(), scfl->source_control_file->core_paragraph->name.c_str());
Assert::AreEqual(size_t(vec.size()), feature_list.size());
for (auto&& feature_name : vec)
@@ -79,7 +80,7 @@ namespace UnitTest1
/// </summary>
struct PackageSpecMap
{
- std::unordered_map<std::string, SourceControlFile> map;
+ std::unordered_map<std::string, SourceControlFileLocation> map;
Triplet triplet;
PackageSpecMap(const Triplet& t = Triplet::X86_WINDOWS) noexcept { triplet = t; }
@@ -94,7 +95,8 @@ namespace UnitTest1
{
auto spec = PackageSpec::from_name_and_triplet(scf.core_paragraph->name, triplet);
Assert::IsTrue(spec.has_value());
- map.emplace(scf.core_paragraph->name, std::move(scf));
+ map.emplace(scf.core_paragraph->name,
+ SourceControlFileLocation{std::unique_ptr<SourceControlFile>(std::move(&scf)), ""});
return PackageSpec{*spec.get()};
}
};