diff options
author | Alberto Sartori <alberto.sartori@huawei.com> | 2022-05-09 10:59:45 +0200 |
---|---|---|
committer | Alberto Sartori <alberto.sartori@huawei.com> | 2022-05-09 10:59:45 +0200 |
commit | e3028f4c2fbf34e1fd2ecc675b7533f03043fa3b (patch) | |
tree | c1470faf1cfc5375a6989c21e7f7ffd0368368f8 /test/buildtool/graph_traverser/graph_traverser.test.hpp | |
parent | bd769ae7d72860d201a201cc6e3f68ffa66f4add (diff) | |
download | justbuild-e3028f4c2fbf34e1fd2ecc675b7533f03043fa3b.tar.gz |
allow for run tests in compatibility mode
Diffstat (limited to 'test/buildtool/graph_traverser/graph_traverser.test.hpp')
-rw-r--r-- | test/buildtool/graph_traverser/graph_traverser.test.hpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/test/buildtool/graph_traverser/graph_traverser.test.hpp b/test/buildtool/graph_traverser/graph_traverser.test.hpp index 634c37e1..b1041d73 100644 --- a/test/buildtool/graph_traverser/graph_traverser.test.hpp +++ b/test/buildtool/graph_traverser/graph_traverser.test.hpp @@ -95,7 +95,14 @@ class TestProject { CommandLineArguments clargs{gtargs}; clargs.artifacts = entry_points; - clargs.graph_description = root_dir_ / "graph_description"; + auto const comp_graph = root_dir_ / "graph_description_compatible"; + if (Compatibility::IsCompatible() and + std::filesystem::exists(comp_graph)) { + clargs.graph_description = comp_graph; + } + else { + clargs.graph_description = root_dir_ / "graph_description"; + } clargs.gtargs.jobs = std::max(1U, std::thread::hardware_concurrency()); clargs.gtargs.stage = StageArguments{ kOutputDirPrefix / (example_name_ + std::to_string(id++))}; @@ -233,7 +240,6 @@ class TestProject { CHECK(Statistics::Instance().ActionsQueuedCounter() == 0); CHECK(Statistics::Instance().ActionsCachedCounter() == 0); } - TestProject hello_world_known_cpp("hello_world_known_source", run_local); auto const clargs = hello_world_known_cpp.CmdLineArgs(); |