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

Unified Diff: chrome/test/BUILD.gn

Issue 717923006: Add chrome sync tests to the GN build. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: maybe fix the thing with the stuff Created 6 years, 1 month 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 | « chrome/chrome_tests_unit.gypi ('k') | components/sessions/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/BUILD.gn
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
index c64cf596691786d05af54998b51b3b0bf7888e65..65792a10055f20248cae00a93158ec4dd656140b 100644
--- a/chrome/test/BUILD.gn
+++ b/chrome/test/BUILD.gn
@@ -5,6 +5,12 @@
import("//build/config/features.gni")
import("//build/config/ui.gni")
+gypi_values = exec_script(
+ "//build/gypi_to_gn.py",
+ [ rebase_path("../chrome_tests.gypi") ],
+ "scope",
+ [ "../chrome_tests.gypi" ])
+
# This target exists to reference other test executables to bring these files
# into the build.
group("test") {
@@ -211,3 +217,170 @@ source_set("test_support_unit") {
"//mojo/environment:chromium",
]
}
+
+source_set("sync_integration_test_support") {
+ testonly = true
+
+ sources = rebase_path(gypi_values.test_support_sync_integration_sources,
+ ".", "//chrome")
+ deps = [
+ ":test_support",
+ "//base",
+ "//chrome",
+ "//chrome/browser",
+ "//components/invalidation",
+ "//components/invalidation:test_support",
+ "//net",
+ "//skia",
+ "//sync",
+ "//sync:test_support_sync_testserver",
+ "//sync:test_support_sync_fake_server",
+ "//ui/app_list:test_support",
+ ]
+
+ if (is_mac) {
+ sources -= [
+ "../browser/sync/test/integration/dictionary_helper.cc",
+ "../browser/sync/test/integration/dictionary_helper.h",
+ "../browser/sync/test/integration/dictionary_load_observer.cc",
+ "../browser/sync/test/integration/dictionary_load_observer.h",
+ ]
+ }
+ if (!enable_app_list) {
+ sources -= [
+ "../browser/sync/test/integration/sync_app_list_helper.cc",
+ "../browser/sync/test/integration/sync_app_list_helper.h",
+ ]
+ }
+}
+
+test("sync_integration_tests") {
+ sources = rebase_path(gypi_values.sync_integration_tests_sources,
+ ".", "//chrome")
+
+ # TODO(phajdan.jr): Only temporary, to make transition easier.
+ defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
+
+ deps = [
+ ":sync_integration_test_support",
+ ":test_support",
+ "//base/allocator",
+ "//chrome:packed_extra_resources",
+ "//chrome:packed_resources",
+ "//chrome:resources",
+ "//chrome:strings",
+ "//chrome/common",
+ "//chrome/renderer",
+ "//crypto:platform",
+ "//sync",
+ "//testing/gmock",
+ "//testing/gtest",
+ "//third_party/icu",
+ "//third_party/leveldatabase",
+ "//third_party/npapi",
+ "//third_party/WebKit/public:blink",
+ ]
+
+ if (cld_version == 0 || cld_version == 2) {
+ # Language detection is irrelevant to sync, so it can depend on any
+ # implementation for CLD2. Dynamic is smaller, so go with dynamic.
+ deps += [ "//third_party/cld_2:cld2_dynamic" ]
+ }
+ if (is_mac) {
+ # Dictionary sync is disabled on Mac.
+ sources -= [
+ "../browser/sync/test/integration/multiple_client_dictionary_sync_test.cc",
+ "../browser/sync/test/integration/single_client_dictionary_sync_test.cc",
+ "../browser/sync/test/integration/two_client_dictionary_sync_test.cc",
+ ]
+
+ # The sync_integration_tests do not run on mac without this flag.
+ # Search for comments about "xcode_settings" elsewhere in this file.
+ ldflags = [ "-Wl,-ObjC" ]
+ }
+ if (is_win) {
+ # TODO(GYP) figure out what these should map to.
+ #sources += [
+ # '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
+ # '<(SHARED_INTERMEDIATE_DIR)/ui/resources/ui_unscaled_resources.rc',
+ #]
+ deps += [
+ "//third_party/wtl",
+ #'chrome_version_resources', TODO(GYP)
+ ]
+ } else {
+ sources -= [
+ "../app/chrome_version.rc.version",
+ ]
+ }
+
+ if (toolkit_views) {
+ deps += [ "//ui/views" ]
+ }
+ if (enable_basic_printing || enable_print_preview) {
+ deps += [ "//printing" ]
+ }
+ if (!enable_app_list) {
+ sources -= [
+ "../browser/sync/test/integration/single_client_app_list_sync_test.cc",
+ "../browser/sync/test/integration/two_client_app_list_sync_test.cc",
+ ]
+ }
+ if (!enable_managed_users) {
+ sources -= [
+ "../browser/sync/test/integration/single_client_supervised_user_settings_sync_test.cc",
+ ]
+ }
+}
+
+test("sync_performance_tests") {
+ sources = rebase_path(gypi_values.sync_performance_tests_sources,
+ ".", "//chrome")
+
+ defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
+
+ deps = [
+ ":sync_integration_test_support",
+ "//base/allocator",
+ "//crypto:platform",
+ "//sync",
+ "//testing/gmock",
+ "//testing/gtest",
+ ]
+
+ if (cld_version == 0 || cld_version == 2) {
+ # Language detection is irrelevant to sync, so it can depend on any
+ # implementation for CLD2. Dynamic is smaller, so go with dynamic.
+ deps += [ "//third_party/cld_2:cld2_dynamic" ]
+ }
+
+ if (is_mac) {
+ # Dictionary sync is disabled on Mac.
+ sources -= [
+ "../browser/sync/test/integration/performance/dictionary_sync_perf_test.cc",
+ ]
+
+ # The sync_performance_tests do not run on mac without this flag.
+ # Search for comments about "xcode_settings" elsewhere in this file.
+ ldflags = [ "-Wl,-ObjC" ]
+ }
+ if (is_win) {
+ # TODO(GYP) figure out what these should map to.
+ #sources += [
+ # '<(SHARED_INTERMEDIATE_DIR)/chrome_version/other_version.rc',
+ # '<(SHARED_INTERMEDIATE_DIR)/ui/resources/ui_unscaled_resources.rc',
+ #]
+ deps += [
+ "//third_party/wtl",
+ #'chrome_version_resources', TODO(GYP)
+ ]
+ } else {
+ sources -= [
+ "../app/chrome_version.rc.version",
+ ]
+ }
+
+ if (toolkit_views) {
+ deps += [ "//ui/views" ]
+ }
+}
« no previous file with comments | « chrome/chrome_tests_unit.gypi ('k') | components/sessions/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698