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

Unified Diff: android_webview/test/embedded_test_server/aw_test_jni_onload.cc

Issue 2687573002: [Android Webview] Refactor LoadUrlTest and work on embedded_test_server custom handler (Closed)
Patch Set: Change AwETS intent class name Created 3 years, 6 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: android_webview/test/embedded_test_server/aw_test_jni_onload.cc
diff --git a/android_webview/test/embedded_test_server/aw_test_jni_onload.cc b/android_webview/test/embedded_test_server/aw_test_jni_onload.cc
new file mode 100644
index 0000000000000000000000000000000000000000..3edd2232bd948c72b62209273faf91b8ae0e9ec7
--- /dev/null
+++ b/android_webview/test/embedded_test_server/aw_test_jni_onload.cc
@@ -0,0 +1,35 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "android_webview/test/embedded_test_server/aw_test_jni_onload.h"
+
+#include "android_webview/test/embedded_test_server/aw_embedded_test_server.h"
+#include "base/android/base_jni_onload.h"
+#include "base/android/base_jni_registrar.h"
+#include "base/android/jni_android.h"
+#include "base/bind.h"
+#include "net/test/android/net_test_jni_onload.h"
+#include "net/test/embedded_test_server/android/embedded_test_server_android.h"
+
+namespace android_webview {
+namespace test {
+
+namespace {
+
+bool RegisterJNI(JNIEnv* env) {
+ return android_webview::test::RegisterCustomHandlers(env);
+}
+
+} // namesapce
+
+bool OnJNIOnLoadRegisterJNI(JNIEnv* env) {
+ return net::test::OnJNIOnLoadRegisterJNI(env) && RegisterJNI(env);
+}
+
+bool OnJNIOnLoadInit() {
+ return base::android::OnJNIOnLoadInit();
+}
+
+} // namespace test
+} // namespace android_webview

Powered by Google App Engine
This is Rietveld 408576698