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

Unified Diff: components/leveldb/BUILD.gn

Issue 1812263004: Convert leveldb_apptests to unit tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase to ToT 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
Index: components/leveldb/BUILD.gn
diff --git a/components/leveldb/BUILD.gn b/components/leveldb/BUILD.gn
index a68f5ecfc775c72fcd792513f84e28841905dd28..02af9b5b091b0e1791bf1f53854983572b4b300c 100644
--- a/components/leveldb/BUILD.gn
+++ b/components/leveldb/BUILD.gn
@@ -4,6 +4,7 @@
import("//mojo/public/mojo_application.gni")
import("//mojo/public/mojo_application_manifest.gni")
+import("//testing/test.gni")
source_set("lib") {
sources = [
@@ -58,13 +59,11 @@ mojo_application_manifest("manifest") {
source = "manifest.json"
}
-mojo_native_application("apptests") {
- output_name = "leveldb_apptests"
-
- testonly = true
+test("unittests") {
+ output_name = "leveldb_service_unittests"
sources = [
- "leveldb_apptest.cc",
+ "leveldb_service_unittest.cc",
]
deps = [
@@ -72,19 +71,22 @@ mojo_native_application("apptests") {
"//components/filesystem/public/interfaces",
"//components/leveldb/public/interfaces",
"//mojo/common",
- "//mojo/platform_handle:for_shared_library",
+ "//mojo/platform_handle",
"//mojo/public/cpp/bindings",
- "//mojo/shell/public/cpp:test_support",
+ "//mojo/shell/public/cpp:shell_test_support",
+ "//mojo/shell/public/cpp:sources",
+ "//mojo/shell/public/cpp/test:run_all_shelltests",
]
data_deps = [
- ":apptest_manifest",
+ ":test_manifest",
":leveldb",
"//components/filesystem:filesystem",
]
}
-mojo_application_manifest("apptest_manifest") {
- application_name = "leveldb_apptests"
- source = "apptest_manifest.json"
+mojo_application_manifest("test_manifest") {
+ type = "exe"
+ application_name = "leveldb_service_unittests"
+ source = "test_manifest.json"
}

Powered by Google App Engine
This is Rietveld 408576698