| 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 # ============================================================================== | 5 # ============================================================================== |
| 6 # TEST SETUP | 6 # TEST SETUP |
| 7 # ============================================================================== | 7 # ============================================================================== |
| 8 | 8 |
| 9 # Define a test as an executable (or apk on Android) with the "testonly" flag | 9 # Define a test as an executable (or apk on Android) with the "testonly" flag |
| 10 # set. | 10 # set. |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 } else { | 169 } else { |
| 170 apk_target = ":$_apk_target" | 170 apk_target = ":$_apk_target" |
| 171 } | 171 } |
| 172 test_name = _output_name | 172 test_name = _output_name |
| 173 test_type = "gtest" | 173 test_type = "gtest" |
| 174 test_suite = _output_name | 174 test_suite = _output_name |
| 175 } | 175 } |
| 176 | 176 |
| 177 group(target_name) { | 177 group(target_name) { |
| 178 testonly = true | 178 testonly = true |
| 179 deps = [ | 179 if (incremental_apk_by_default && !_use_raw_android_executable) { |
| 180 ":$_test_runner_target", | 180 deps = [ |
| 181 ] | 181 ":${target_name}_incremental", |
| 182 if (_use_raw_android_executable) { | 182 ] |
| 183 deps += [ ":$_dist_target" ] | |
| 184 } else { | 183 } else { |
| 185 deps += [ ":$_apk_target" ] | 184 deps = [ |
| 185 ":$_test_runner_target", |
| 186 ] |
| 187 if (_use_raw_android_executable) { |
| 188 deps += [ ":$_dist_target" ] |
| 189 } else { |
| 190 deps += [ ":$_apk_target" ] |
| 191 } |
| 186 } | 192 } |
| 187 } | 193 } |
| 188 | 194 |
| 189 # TODO(GYP_GONE): Delete this after we've converted everything to GN. | 195 # TODO(GYP_GONE): Delete this after we've converted everything to GN. |
| 190 # The _run targets exist only for compatibility w/ GYP. | 196 # The _run targets exist only for compatibility w/ GYP. |
| 191 group("${target_name}_apk_run") { | 197 group("${target_name}_apk_run") { |
| 192 testonly = true | 198 testonly = true |
| 193 deps = [ | 199 deps = [ |
| 194 ":${invoker.target_name}", | 200 ":${invoker.target_name}", |
| 195 ] | 201 ] |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 284 } | 290 } |
| 285 | 291 |
| 286 # Test defaults. | 292 # Test defaults. |
| 287 set_defaults("test") { | 293 set_defaults("test") { |
| 288 if (is_android) { | 294 if (is_android) { |
| 289 configs = default_shared_library_configs | 295 configs = default_shared_library_configs |
| 290 } else { | 296 } else { |
| 291 configs = default_executable_configs | 297 configs = default_executable_configs |
| 292 } | 298 } |
| 293 } | 299 } |
| OLD | NEW |