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

Unified Diff: components/cronet/android/test/src/org/chromium/net/QuicTestServer.java

Issue 1412243012: Initial implementation of CronetBidirectionalStream. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More Helen's and Andrei's comments. Created 4 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
Index: components/cronet/android/test/src/org/chromium/net/QuicTestServer.java
diff --git a/components/cronet/android/test/src/org/chromium/net/QuicTestServer.java b/components/cronet/android/test/src/org/chromium/net/QuicTestServer.java
index 44c414f8bb48d2b45c9ec168ca8f9b2c386b23b0..1344cc4d5c8114ae573571c4cdcc8ed0a5223f22 100644
--- a/components/cronet/android/test/src/org/chromium/net/QuicTestServer.java
+++ b/components/cronet/android/test/src/org/chromium/net/QuicTestServer.java
@@ -19,6 +19,10 @@ public final class QuicTestServer {
private static final ConditionVariable sBlock = new ConditionVariable();
private static final String TAG = "cr.QuicTestServer";
+ private static final String CERT_USED = "quic_test.example.com.crt";
+ private static final String KEY_USED = "quic_test.example.com.key";
+ private static final String[] CERTS_USED = {CERT_USED};
+
public static void startQuicTestServer(Context context) {
TestFilesInstaller.installIfNeeded(context);
nativeStartQuicTestServer(TestFilesInstaller.getInstalledPath(context));
@@ -42,6 +46,18 @@ public final class QuicTestServer {
return nativeGetServerPort();
}
+ public static final String getServerCert() {
+ return CERT_USED;
+ }
+
+ public static final String getServerCertKey() {
+ return KEY_USED;
+ }
+
+ public static long createMockCertVerifier() {
+ return MockCertVerifier.createMockCertVerifier(CERTS_USED);
+ }
+
@CalledByNative
private static void onServerStarted() {
Log.i(TAG, "Quic server started.");

Powered by Google App Engine
This is Rietveld 408576698