Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(22)

Unified Diff: tools/gn/filesystem_utils_unittest.cc

Issue 1316653003: GN get_label_info support toolchains for target_out_dir. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/filesystem_utils.cc ('k') | tools/gn/function_get_label_info.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/filesystem_utils_unittest.cc
diff --git a/tools/gn/filesystem_utils_unittest.cc b/tools/gn/filesystem_utils_unittest.cc
index 14bc9515307e3767a108ff2f358a7789b68eb7a5..9f89512cfa29f1260d20488e9a67a6feaed4e448 100644
--- a/tools/gn/filesystem_utils_unittest.cc
+++ b/tools/gn/filesystem_utils_unittest.cc
@@ -480,7 +480,10 @@ TEST(FilesystemUtils, GetOutDirForSourceDir) {
build_settings.SetBuildDir(SourceDir("//out/Debug/"));
// Test the default toolchain.
+ Label default_toolchain_label(SourceDir("//toolchain/"), "default");
Settings default_settings(&build_settings, "");
+ default_settings.set_toolchain_label(default_toolchain_label);
+ default_settings.set_default_toolchain_label(default_toolchain_label);
EXPECT_EQ("//out/Debug/obj/",
GetOutputDirForSourceDir(
&default_settings, SourceDir("//")).value());
@@ -497,6 +500,8 @@ TEST(FilesystemUtils, GetOutDirForSourceDir) {
// Secondary toolchain.
Settings other_settings(&build_settings, "two/");
+ other_settings.set_toolchain_label(Label(SourceDir("//toolchain/"), "two"));
+ other_settings.set_default_toolchain_label(default_toolchain_label);
EXPECT_EQ("//out/Debug/two/obj/",
GetOutputDirForSourceDir(
&other_settings, SourceDir("//")).value());
« no previous file with comments | « tools/gn/filesystem_utils.cc ('k') | tools/gn/function_get_label_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698