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

Unified Diff: sandbox/linux/BUILD.gn

Issue 1848033005: Revert of 🍬 GN: Make breakpad_unittests & sandbox_linux_unittests use test() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@test-minor-renames
Patch Set: Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/config/android/rules.gni ('k') | testing/test.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/linux/BUILD.gn
diff --git a/sandbox/linux/BUILD.gn b/sandbox/linux/BUILD.gn
index 4b5d126509291a58f518a4043592ed1323bce74a..e08f42b35f7ca259fe4a80bb9e3ccc506803c098 100644
--- a/sandbox/linux/BUILD.gn
+++ b/sandbox/linux/BUILD.gn
@@ -192,14 +192,33 @@
rebase_path(outputs, root_build_dir) + rebase_path(inputs, root_build_dir)
}
-test("sandbox_linux_unittests") {
+# TODO(GYP): Delete these after we've converted everything to GN.
+# The _run targets exist only for compatibility w/ GYP.
+group("sandbox_linux_unittests_run") {
+ testonly = true
+ deps = [
+ ":sandbox_linux_unittests",
+ ]
+}
+
+if (is_android) {
+ group("sandbox_linux_unittests_apk_run") {
+ testonly = true
+ deps = [
+ ":sandbox_linux_unittests",
+ ]
+ }
+}
+
+# The main sandboxing test target. "sandbox_linux_unittests" cannot use the
+# test() template because the test is run as an executable not as an APK on
+# Android.
+executable("sandbox_linux_unittests") {
+ testonly = true
deps = [
":sandbox_linux_unittests_sources",
"//build/config/sanitizers:deps",
]
- if (is_android) {
- use_raw_android_executable = true
- }
}
component("seccomp_bpf") {
@@ -435,11 +454,23 @@
}
if (is_android) {
- # TODO(GYP) Delete this after we've converted everything to GN.
- group("sandbox_linux_unittests_deps") {
+ create_native_executable_dist("sandbox_linux_unittests_deps") {
testonly = true
+ dist_dir = "$root_out_dir/sandbox_linux_unittests_deps"
+ binary = "$root_out_dir/sandbox_linux_unittests"
deps = [
":sandbox_linux_unittests",
]
- }
-}
+
+ if (is_component_build) {
+ deps += [ "//build/android:cpplib_stripped" ]
+ }
+ }
+
+ test_runner_script("sandbox_linux_unittests__test_runner_script") {
+ test_name = "sandbox_linux_unittests"
+ test_type = "gtest"
+ test_suite = "sandbox_linux_unittests"
+ isolate_file = "//sandbox/sandbox_linux_unittests_android.isolate"
+ }
+}
« no previous file with comments | « build/config/android/rules.gni ('k') | testing/test.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698