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

Unified Diff: mojo/edk/js/tests/BUILD.gn

Issue 2645873003: Cleanup mojo-js tests. (Closed)
Patch Set: more deps fixes Created 3 years, 11 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 | « mojo/edk/js/test/run_js_tests.cc ('k') | mojo/edk/js/tests/binding_tests.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/js/tests/BUILD.gn
diff --git a/mojo/edk/js/tests/BUILD.gn b/mojo/edk/js/tests/BUILD.gn
index 693a03ce254ceb679bb2a37ccc68d69cde6c5946..41850d78a8bbd6f9aba81fc96d6eb18deffe603a 100644
--- a/mojo/edk/js/tests/BUILD.gn
+++ b/mojo/edk/js/tests/BUILD.gn
@@ -2,21 +2,34 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
-import("../../../../mojo/public/tools/bindings/mojom.gni")
+import("//mojo/public/tools/bindings/mojom.gni")
+import("//testing/test.gni")
-source_set("js_to_cpp_tests") {
+# TODO(hansmuller): The organization of tests in this directory is weird:
+# * Really, js_unittests tests public stuff, so that should live in public
+# and be reworked as some sort of apptest.
+# * Both js_unittests and js_integration_tests should auto-generate their
+# tests somehow. The .cc files are just test runner stubs, including
+# explicit lists of .js files.
+
+group("tests") {
testonly = true
+ deps = [
+ ":mojo_js_integration_tests",
+ ":mojo_js_unittests",
+ ]
+}
+test("mojo_js_integration_tests") {
deps = [
":js_to_cpp_bindings",
"//gin:gin_test",
"//mojo/common",
"//mojo/edk/js",
- "//mojo/edk/test:test_support",
+ "//mojo/edk/test:run_all_unittests",
"//mojo/public/cpp/bindings",
"//mojo/public/cpp/system",
- "//mojo/public/interfaces/bindings/tests:test_interfaces",
- "//mojo/public/interfaces/bindings/tests:test_interfaces_experimental",
+ "//mojo/public/js:bindings",
]
sources = [
@@ -24,11 +37,7 @@ source_set("js_to_cpp_tests") {
]
data = [
- "binding_tests.js",
- "connection_tests.js",
- "interface_ptr_tests.js",
"js_to_cpp_tests.js",
- "sample_service_tests.js",
]
configs += [ "//v8:external_startup_data" ]
@@ -39,3 +48,22 @@ mojom("js_to_cpp_bindings") {
"js_to_cpp.mojom",
]
}
+
+test("mojo_js_unittests") {
+ deps = [
+ "//base",
+ "//gin:gin_test",
+ "//mojo/edk/js",
+ "//mojo/edk/test:run_all_unittests",
+ "//mojo/edk/test:test_support",
+ "//mojo/public/cpp/system",
+ "//mojo/public/interfaces/bindings/tests:test_interfaces",
+ "//mojo/public/interfaces/bindings/tests:test_interfaces_experimental",
+ "//mojo/public/js:tests",
+ ]
+
+ sources = [
+ "//mojo/edk/js/handle_unittest.cc",
+ "run_js_unittests.cc",
+ ]
+}
« no previous file with comments | « mojo/edk/js/test/run_js_tests.cc ('k') | mojo/edk/js/tests/binding_tests.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698