OLD | NEW |
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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/features.gni") | 5 import("//build/config/features.gni") |
6 import("//testing/test.gni") | 6 import("//testing/test.gni") |
7 | 7 |
8 if (is_android) { | 8 if (is_android) { |
9 import("//build/config/android/rules.gni") # For generate_jni(). | 9 import("//build/config/android/rules.gni") # For generate_jni(). |
10 } | 10 } |
(...skipping 12 matching lines...) Expand all Loading... |
23 deps = [ | 23 deps = [ |
24 ":device_unittests", | 24 ":device_unittests", |
25 ] | 25 ] |
26 } | 26 } |
27 | 27 |
28 test("device_unittests") { | 28 test("device_unittests") { |
29 sources = [ | 29 sources = [ |
30 "battery/battery_status_manager_win_unittest.cc", | 30 "battery/battery_status_manager_win_unittest.cc", |
31 "battery/battery_status_service_unittest.cc", | 31 "battery/battery_status_service_unittest.cc", |
32 "bluetooth/bluetooth_adapter_mac_unittest.mm", | 32 "bluetooth/bluetooth_adapter_mac_unittest.mm", |
33 "bluetooth/bluetooth_adapter_profile_chromeos_unittest.cc", | |
34 "bluetooth/bluetooth_adapter_unittest.cc", | 33 "bluetooth/bluetooth_adapter_unittest.cc", |
35 "bluetooth/bluetooth_adapter_win_unittest.cc", | 34 "bluetooth/bluetooth_adapter_win_unittest.cc", |
36 "bluetooth/bluetooth_advertisement_chromeos_unittest.cc", | |
37 "bluetooth/bluetooth_advertisement_unittest.cc", | 35 "bluetooth/bluetooth_advertisement_unittest.cc", |
38 "bluetooth/bluetooth_audio_sink_chromeos_unittest.cc", | |
39 "bluetooth/bluetooth_chromeos_unittest.cc", | |
40 "bluetooth/bluetooth_device_unittest.cc", | 36 "bluetooth/bluetooth_device_unittest.cc", |
41 "bluetooth/bluetooth_device_win_unittest.cc", | 37 "bluetooth/bluetooth_device_win_unittest.cc", |
42 "bluetooth/bluetooth_discovery_filter_unittest.cc", | 38 "bluetooth/bluetooth_discovery_filter_unittest.cc", |
43 "bluetooth/bluetooth_gatt_chromeos_unittest.cc", | |
44 "bluetooth/bluetooth_low_energy_win_unittest.cc", | 39 "bluetooth/bluetooth_low_energy_win_unittest.cc", |
45 "bluetooth/bluetooth_service_record_win_unittest.cc", | 40 "bluetooth/bluetooth_service_record_win_unittest.cc", |
46 "bluetooth/bluetooth_socket_chromeos_unittest.cc", | |
47 "bluetooth/bluetooth_task_manager_win_unittest.cc", | 41 "bluetooth/bluetooth_task_manager_win_unittest.cc", |
48 "bluetooth/bluetooth_uuid_unittest.cc", | 42 "bluetooth/bluetooth_uuid_unittest.cc", |
49 "bluetooth/test/bluetooth_test.cc", | 43 "bluetooth/test/bluetooth_test.cc", |
50 "bluetooth/test/bluetooth_test.h", | 44 "bluetooth/test/bluetooth_test.h", |
51 "bluetooth/test/bluetooth_test_android.cc", | 45 "bluetooth/test/bluetooth_test_android.cc", |
52 "bluetooth/test/bluetooth_test_android.h", | 46 "bluetooth/test/bluetooth_test_android.h", |
53 "bluetooth/test/bluetooth_test_mac.h", | 47 "bluetooth/test/bluetooth_test_mac.h", |
54 "bluetooth/test/bluetooth_test_mac.mm", | 48 "bluetooth/test/bluetooth_test_mac.mm", |
55 "bluetooth/test/test_bluetooth_adapter_observer.cc", | 49 "bluetooth/test/test_bluetooth_adapter_observer.cc", |
56 "bluetooth/test/test_bluetooth_adapter_observer.h", | 50 "bluetooth/test/test_bluetooth_adapter_observer.h", |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 } | 128 } |
135 | 129 |
136 if (is_android) { | 130 if (is_android) { |
137 sources -= [ "battery/battery_status_service_unittest.cc" ] | 131 sources -= [ "battery/battery_status_service_unittest.cc" ] |
138 deps -= [ "//device/battery" ] | 132 deps -= [ "//device/battery" ] |
139 deps += [ ":bluetooth_test_jni_headers" ] | 133 deps += [ ":bluetooth_test_jni_headers" ] |
140 apk_deps = [ ":bluetooth_test_java" ] | 134 apk_deps = [ ":bluetooth_test_java" ] |
141 } | 135 } |
142 | 136 |
143 if (is_chromeos) { | 137 if (is_chromeos) { |
144 configs += [ "//build/config/linux:dbus" ] | |
145 | |
146 deps += [ | 138 deps += [ |
147 "//chromeos", | 139 "//chromeos", |
148 "//chromeos:test_support", | 140 "//chromeos:test_support", |
149 "//chromeos:test_support_without_gmock", | 141 "//chromeos:test_support_without_gmock", |
150 "//dbus", | |
151 ] | 142 ] |
152 } | 143 } |
153 | 144 |
| 145 if (is_chromeos || is_linux) { |
| 146 configs += [ "//build/config/linux:dbus" ] |
| 147 |
| 148 sources += [ |
| 149 "bluetooth/bluetooth_adapter_profile_bluez_unittest.cc", |
| 150 "bluetooth/bluetooth_advertisement_bluez_unittest.cc", |
| 151 "bluetooth/bluetooth_audio_sink_bluez_unittest.cc", |
| 152 "bluetooth/bluetooth_bluez_unittest.cc", |
| 153 "bluetooth/bluetooth_gatt_bluez_unittest.cc", |
| 154 "bluetooth/bluetooth_socket_bluez_unittest.cc", |
| 155 ] |
| 156 |
| 157 deps += [ "//dbus" ] |
| 158 } |
| 159 |
154 if (is_posix && !is_android && !is_mac) { | 160 if (is_posix && !is_android && !is_mac) { |
155 libs = [ "rt" ] | 161 libs = [ "rt" ] |
156 } | 162 } |
157 | 163 |
158 if (is_mac) { | 164 if (is_mac) { |
159 deps += [ "//third_party/ocmock" ] | 165 deps += [ "//third_party/ocmock" ] |
160 ldflags = [ "-ObjC" ] | 166 ldflags = [ "-ObjC" ] |
161 libs = [ "IOBluetooth.framework" ] | 167 libs = [ "IOBluetooth.framework" ] |
162 | 168 |
163 # In the OSX 10.10 SDK, CoreBluetooth became a top level framework. | 169 # In the OSX 10.10 SDK, CoreBluetooth became a top level framework. |
(...skipping 15 matching lines...) Expand all Loading... |
179 } | 185 } |
180 | 186 |
181 android_library("bluetooth_test_java") { | 187 android_library("bluetooth_test_java") { |
182 java_files = bluetooth_java_sources_needing_jni | 188 java_files = bluetooth_java_sources_needing_jni |
183 deps = [ | 189 deps = [ |
184 "//base:base_java", | 190 "//base:base_java", |
185 "//device/bluetooth:java", | 191 "//device/bluetooth:java", |
186 ] | 192 ] |
187 } | 193 } |
188 } | 194 } |
OLD | NEW |