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

Side by Side Diff: ios/chrome/search_widget_extension/BUILD.gn

Issue 2810403003: Add unit test and showcase support for search widget. (Closed)
Patch Set: rebase Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 # Copyright 2017 The Chromium Authors. All rights reserved. 1 # Copyright 2017 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import("//build/config/ios/rules.gni") 5 import("//build/config/ios/rules.gni")
6 import("//build/config/mac/base_rules.gni") 6 import("//build/config/mac/base_rules.gni")
7 import("//build/mac/tweak_info_plist.gni") 7 import("//build/mac/tweak_info_plist.gni")
8 import("//ios/build/chrome_build.gni") 8 import("//ios/build/chrome_build.gni")
9 9
10 tweak_info_plist("tweak_info_plist") { 10 tweak_info_plist("tweak_info_plist") {
11 info_plist = "Info.plist" 11 info_plist = "Info.plist"
12 } 12 }
13 13
14 compile_plist("entitlements") { 14 compile_plist("entitlements") {
15 format = "xml1" 15 format = "xml1"
16 substitutions = [ "IOS_BUNDLE_ID_PREFIX=$ios_app_bundle_id_prefix" ] 16 substitutions = [ "IOS_BUNDLE_ID_PREFIX=$ios_app_bundle_id_prefix" ]
17 output_name = "$target_gen_dir/search_widget_extension.appex.entitlements" 17 output_name = "$target_gen_dir/search_widget_extension.appex.entitlements"
18 plist_templates = 18 plist_templates =
19 [ "entitlements/external/search_widget_extension.appex.entitlements" ] 19 [ "entitlements/external/search_widget_extension.appex.entitlements" ]
20 } 20 }
21 21
22 ios_appex_bundle("search_widget_extension") { 22 ios_appex_bundle("search_widget_extension") {
23 deps = [
24 ":search_widget",
25 ]
26
27 extra_substitutions = [
28 "CHROME_CHANNEL_SCHEME=$url_channel_scheme",
29 "CHROMIUM_SHORT_NAME=$chromium_short_name",
30 "WIDGET_EXTENSION_BUNDLE_ID=$chromium_bundle_id.SearchTodayExtension",
31 ]
32
33 configs += [ "//build/config/compiler:enable_arc" ]
sdefresne 2017/04/19 15:54:56 There are no "sources" in that target, so you can
lody 2017/04/19 16:01:53 Done.
34
35 entitlements_target = ":entitlements"
36 info_plist_target = ":tweak_info_plist"
37 }
38
39 source_set("search_widget") {
23 sources = [ 40 sources = [
24 "search_widget_view.h", 41 "search_widget_view.h",
25 "search_widget_view.mm", 42 "search_widget_view.mm",
26 "search_widget_view_controller.h", 43 "search_widget_view_controller.h",
27 "search_widget_view_controller.mm", 44 "search_widget_view_controller.mm",
28 ] 45 ]
29 46
30 deps = [ 47 deps = [
31 "//base", 48 "//base",
32 "//components/open_from_clipboard:open_from_clipboard_impl", 49 "//components/open_from_clipboard:open_from_clipboard_impl",
33 "//components/prefs",
34 "//components/variations",
35 "//components/version_info",
36 "//ios/chrome/common",
37 "//ios/chrome/common/app_group", 50 "//ios/chrome/common/app_group",
38 "//ios/chrome/common/app_group:client",
39 "//ios/chrome/common/physical_web",
40 "//ios/chrome/today_extension/strings",
41 "//ios/third_party/material_components_ios",
42 "//net",
43 "//ui/base",
44 ] 51 ]
45 52
46 libs = [ 53 libs = [
47 "Foundation.framework", 54 "Foundation.framework",
48 "NotificationCenter.framework", 55 "NotificationCenter.framework",
49 "UIKit.framework", 56 "UIKit.framework",
50 ] 57 ]
51 58
52 extra_substitutions = [ 59 configs += [ "//build/config/compiler:enable_arc" ]
53 "CHROME_CHANNEL_SCHEME=$url_channel_scheme", 60 }
54 "CHROMIUM_SHORT_NAME=$chromium_short_name", 61
55 "WIDGET_EXTENSION_BUNDLE_ID=$chromium_bundle_id.SearchTodayExtension", 62 source_set("unit_tests") {
63 testonly = true
64 sources = [
65 "search_widget_view_controller_unittest.mm",
56 ] 66 ]
57 67 deps = [
68 ":search_widget",
69 "//testing/gtest",
70 ]
58 configs += [ "//build/config/compiler:enable_arc" ] 71 configs += [ "//build/config/compiler:enable_arc" ]
59
60 entitlements_target = ":entitlements"
61 info_plist_target = ":tweak_info_plist"
62 } 72 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698