1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
5 import("//build/config/android/rules.gni")
16 generate_jni("jni_headers") {
18 "javatests/src/org/chromium/mojo/MojoTestCase.java",
19 "javatests/src/org/chromium/mojo/bindings/ValidationTestUtil.java",
22 ":system_java_jni_headers",
28 generate_jni("system_java_jni_headers") {
30 "system/src/org/chromium/mojo/system/impl/CoreImpl.java",
31 "system/src/org/chromium/mojo/system/impl/BaseRunLoop.java",
37 source_set("libsystem_java") {
39 "system/base_run_loop.cc",
40 "system/base_run_loop.h",
41 "system/core_impl.cc",
46 ":system_java_jni_headers",
48 "//mojo/environment:chromium",
49 "//mojo/common:common",
50 "//third_party/mojo/src/mojo/edk/system",
51 "//third_party/mojo/src/mojo/public/cpp/environment",
55 android_library("system_java") {
57 "system/src/org/chromium/mojo/system/impl/BaseRunLoop.java",
58 "system/src/org/chromium/mojo/system/impl/CoreImpl.java",
59 "system/src/org/chromium/mojo/system/impl/DataPipeConsumerHandleImpl.java",
60 "system/src/org/chromium/mojo/system/impl/DataPipeProducerHandleImpl.java",
61 "system/src/org/chromium/mojo/system/impl/HandleBase.java",
62 "system/src/org/chromium/mojo/system/impl/MessagePipeHandleImpl.java",
63 "system/src/org/chromium/mojo/system/impl/SharedBufferHandleImpl.java",
64 "system/src/org/chromium/mojo/system/impl/UntypedHandleImpl.java",
69 "//third_party/mojo/src/mojo/public/java:system",
73 android_library("mojo_javatests") {
76 "javatests/src/org/chromium/mojo/HandleMock.java",
77 "javatests/src/org/chromium/mojo/MojoTestCase.java",
78 "javatests/src/org/chromium/mojo/TestUtils.java",
79 "javatests/src/org/chromium/mojo/bindings/BindingsHelperTest.java",
80 "javatests/src/org/chromium/mojo/bindings/BindingsTest.java",
81 "javatests/src/org/chromium/mojo/bindings/BindingsTestUtils.java",
82 "javatests/src/org/chromium/mojo/bindings/BindingsVersioningTest.java",
83 "javatests/src/org/chromium/mojo/bindings/CallbacksTest.java",
84 "javatests/src/org/chromium/mojo/bindings/ConnectorTest.java",
85 "javatests/src/org/chromium/mojo/bindings/ExecutorFactoryTest.java",
86 "javatests/src/org/chromium/mojo/bindings/InterfacesTest.java",
87 "javatests/src/org/chromium/mojo/bindings/MessageHeaderTest.java",
88 "javatests/src/org/chromium/mojo/bindings/ReadAndDispatchMessageTest.java",
89 "javatests/src/org/chromium/mojo/bindings/RouterTest.java",
90 "javatests/src/org/chromium/mojo/bindings/SerializationTest.java",
91 "javatests/src/org/chromium/mojo/bindings/test/mojom/mojo/IntegrationTestInterfaceTestHelper.java",
92 "javatests/src/org/chromium/mojo/bindings/ValidationTest.java",
93 "javatests/src/org/chromium/mojo/bindings/ValidationTestUtil.java",
94 "javatests/src/org/chromium/mojo/bindings/ValidationTestUtilTest.java",
95 "javatests/src/org/chromium/mojo/HandleMock.java",
96 "javatests/src/org/chromium/mojo/MojoTestCase.java",
97 "javatests/src/org/chromium/mojo/TestUtils.java",
98 "javatests/src/org/chromium/mojo/system/impl/CoreImplTest.java",
104 "//base:base_java_test_support",
105 "//third_party/mojo/src/mojo/public/interfaces/bindings/tests:test_interfaces_java",
106 "//third_party/mojo/src/mojo/public/java:bindings",
107 "//third_party/mojo/src/mojo/public/java:system",
111 shared_library("mojo_java_unittests") {
115 "javatests/init_library.cc",
116 "javatests/mojo_test_case.cc",
117 "javatests/mojo_test_case.h",
118 "javatests/validation_test_util.cc",
119 "javatests/validation_test_util.h",
125 ":system_java_jni_headers",
127 "//base/test/:test_support",
129 "//third_party/mojo/src/mojo/edk/system",
130 "//third_party/mojo/src/mojo/public/cpp/bindings/tests:mojo_public_bindings_test_utils",
131 "//third_party/mojo/src/mojo/public/cpp/test_support:test_utils",
132 "//third_party/mojo/src/mojo/public/cpp/environment",
134 defines = [ "UNIT_TEST" ]
137 android_apk("mojo_test_apk") {
141 ":mojo_java_unittests",
144 "//third_party/mojo/src/mojo/public/java:bindings",
145 "//third_party/mojo/src/mojo/public/interfaces/bindings/tests:test_interfaces",
147 native_libs = [ "libmojo_java_unittests.so" ]
148 apk_name = "MojoTest"
149 android_manifest = "javatests/AndroidManifest.xml"