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_characteristic_unittest.cc", | 39 "bluetooth/bluetooth_gatt_characteristic_unittest.cc", |
44 "bluetooth/bluetooth_gatt_chromeos_unittest.cc", | |
45 "bluetooth/bluetooth_gatt_service_unittest.cc", | 40 "bluetooth/bluetooth_gatt_service_unittest.cc", |
46 "bluetooth/bluetooth_low_energy_win_unittest.cc", | 41 "bluetooth/bluetooth_low_energy_win_unittest.cc", |
47 "bluetooth/bluetooth_service_record_win_unittest.cc", | 42 "bluetooth/bluetooth_service_record_win_unittest.cc", |
48 "bluetooth/bluetooth_socket_chromeos_unittest.cc", | |
49 "bluetooth/bluetooth_task_manager_win_unittest.cc", | 43 "bluetooth/bluetooth_task_manager_win_unittest.cc", |
50 "bluetooth/bluetooth_uuid_unittest.cc", | 44 "bluetooth/bluetooth_uuid_unittest.cc", |
51 "bluetooth/test/bluetooth_test.cc", | 45 "bluetooth/test/bluetooth_test.cc", |
52 "bluetooth/test/bluetooth_test.h", | 46 "bluetooth/test/bluetooth_test.h", |
53 "bluetooth/test/bluetooth_test_android.cc", | 47 "bluetooth/test/bluetooth_test_android.cc", |
54 "bluetooth/test/bluetooth_test_android.h", | 48 "bluetooth/test/bluetooth_test_android.h", |
55 "bluetooth/test/bluetooth_test_mac.h", | 49 "bluetooth/test/bluetooth_test_mac.h", |
56 "bluetooth/test/bluetooth_test_mac.mm", | 50 "bluetooth/test/bluetooth_test_mac.mm", |
57 "bluetooth/test/test_bluetooth_adapter_observer.cc", | 51 "bluetooth/test/test_bluetooth_adapter_observer.cc", |
58 "bluetooth/test/test_bluetooth_adapter_observer.h", | 52 "bluetooth/test/test_bluetooth_adapter_observer.h", |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 } | 133 } |
140 | 134 |
141 if (is_android) { | 135 if (is_android) { |
142 sources -= [ "battery/battery_status_service_unittest.cc" ] | 136 sources -= [ "battery/battery_status_service_unittest.cc" ] |
143 deps -= [ "//device/battery" ] | 137 deps -= [ "//device/battery" ] |
144 deps += [ ":bluetooth_test_jni_headers" ] | 138 deps += [ ":bluetooth_test_jni_headers" ] |
145 apk_deps = [ ":bluetooth_test_java" ] | 139 apk_deps = [ ":bluetooth_test_java" ] |
146 } | 140 } |
147 | 141 |
148 if (is_chromeos) { | 142 if (is_chromeos) { |
149 configs += [ "//build/config/linux:dbus" ] | |
150 | |
151 deps += [ | 143 deps += [ |
152 "//chromeos", | 144 "//chromeos", |
153 "//chromeos:test_support", | 145 "//chromeos:test_support", |
154 "//chromeos:test_support_without_gmock", | 146 "//chromeos:test_support_without_gmock", |
155 "//dbus", | |
156 ] | 147 ] |
157 } | 148 } |
158 | 149 |
| 150 if (is_chromeos || is_linux) { |
| 151 configs += [ "//build/config/linux:dbus" ] |
| 152 |
| 153 sources += [ |
| 154 "bluetooth/bluetooth_adapter_profile_bluez_unittest.cc", |
| 155 "bluetooth/bluetooth_advertisement_bluez_unittest.cc", |
| 156 "bluetooth/bluetooth_audio_sink_bluez_unittest.cc", |
| 157 "bluetooth/bluetooth_bluez_unittest.cc", |
| 158 "bluetooth/bluetooth_gatt_bluez_unittest.cc", |
| 159 "bluetooth/bluetooth_socket_bluez_unittest.cc", |
| 160 ] |
| 161 |
| 162 deps += [ "//dbus" ] |
| 163 } |
| 164 |
159 if (is_posix && !is_android && !is_mac) { | 165 if (is_posix && !is_android && !is_mac) { |
160 libs = [ "rt" ] | 166 libs = [ "rt" ] |
161 } | 167 } |
162 | 168 |
163 if (is_mac) { | 169 if (is_mac) { |
164 deps += [ "//third_party/ocmock" ] | 170 deps += [ "//third_party/ocmock" ] |
165 ldflags = [ "-ObjC" ] | 171 ldflags = [ "-ObjC" ] |
166 libs = [ "IOBluetooth.framework" ] | 172 libs = [ "IOBluetooth.framework" ] |
167 | 173 |
168 # In the OSX 10.10 SDK, CoreBluetooth became a top level framework. | 174 # In the OSX 10.10 SDK, CoreBluetooth became a top level framework. |
(...skipping 18 matching lines...) Expand all Loading... |
187 } | 193 } |
188 | 194 |
189 android_library("bluetooth_test_java") { | 195 android_library("bluetooth_test_java") { |
190 java_files = bluetooth_java_sources_needing_jni | 196 java_files = bluetooth_java_sources_needing_jni |
191 deps = [ | 197 deps = [ |
192 "//base:base_java", | 198 "//base:base_java", |
193 "//device/bluetooth:java", | 199 "//device/bluetooth:java", |
194 ] | 200 ] |
195 } | 201 } |
196 } | 202 } |
OLD | NEW |