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

Side by Side Diff: components/cronet/android/test/javatests/src/org/chromium/net/QuicTest.java

Issue 2120703003: QUIC - Race Cert Verification with host resolution if certs are (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix for buildbot failure. Created 4 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.net; 5 package org.chromium.net;
6 6
7 import android.os.ConditionVariable; 7 import android.os.ConditionVariable;
8 import android.test.suitebuilder.annotation.LargeTest; 8 import android.test.suitebuilder.annotation.LargeTest;
9 import android.test.suitebuilder.annotation.SmallTest; 9 import android.test.suitebuilder.annotation.SmallTest;
10 10
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 JSONObject quicParams = new JSONObject() 44 JSONObject quicParams = new JSONObject()
45 .put("connection_options", "PACE,IW10,FO O,DEADBEEF") 45 .put("connection_options", "PACE,IW10,FO O,DEADBEEF")
46 .put("host_whitelist", "test.example.com ") 46 .put("host_whitelist", "test.example.com ")
47 .put("max_server_configs_stored_in_prope rties", 2) 47 .put("max_server_configs_stored_in_prope rties", 2)
48 .put("delay_tcp_race", true) 48 .put("delay_tcp_race", true)
49 .put("max_number_of_lossy_connections", 10) 49 .put("max_number_of_lossy_connections", 10)
50 .put("packet_loss_threshold", 0.5) 50 .put("packet_loss_threshold", 0.5)
51 .put("idle_connection_timeout_seconds", 300) 51 .put("idle_connection_timeout_seconds", 300)
52 .put("close_sessions_on_ip_change", fals e) 52 .put("close_sessions_on_ip_change", fals e)
53 .put("migrate_sessions_on_network_change ", true) 53 .put("migrate_sessions_on_network_change ", true)
54 .put("migrate_sessions_early", true); 54 .put("migrate_sessions_early", true)
55 .put("race_cert_verification", true);
55 JSONObject experimentalOptions = new JSONObject().put("QUIC", quicParams ); 56 JSONObject experimentalOptions = new JSONObject().put("QUIC", quicParams );
56 mBuilder.setExperimentalOptions(experimentalOptions.toString()); 57 mBuilder.setExperimentalOptions(experimentalOptions.toString());
57 mBuilder.setMockCertVerifierForTesting(QuicTestServer.createMockCertVeri fier()); 58 mBuilder.setMockCertVerifierForTesting(QuicTestServer.createMockCertVeri fier());
58 mBuilder.setStoragePath(CronetTestFramework.getTestStorage(getContext()) ); 59 mBuilder.setStoragePath(CronetTestFramework.getTestStorage(getContext()) );
59 mBuilder.enableHttpCache(CronetEngine.Builder.HTTP_CACHE_DISK_NO_HTTP, 1 000 * 1024); 60 mBuilder.enableHttpCache(CronetEngine.Builder.HTTP_CACHE_DISK_NO_HTTP, 1 000 * 1024);
60 } 61 }
61 62
62 @Override 63 @Override
63 protected void tearDown() throws Exception { 64 protected void tearDown() throws Exception {
64 QuicTestServer.shutdownQuicTestServer(); 65 QuicTestServer.shutdownQuicTestServer();
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 assertTrue(rttListener.rttObservationCount(2) > 0); 224 assertTrue(rttListener.rttObservationCount(2) > 0);
224 225
225 // Verify that effective connection type callback is received and 226 // Verify that effective connection type callback is received and
226 // effective connection type is correctly set. 227 // effective connection type is correctly set.
227 assertTrue(mTestFramework.mCronetEngine.getEffectiveConnectionType() 228 assertTrue(mTestFramework.mCronetEngine.getEffectiveConnectionType()
228 != EffectiveConnectionType.EFFECTIVE_CONNECTION_TYPE_UNKNOWN); 229 != EffectiveConnectionType.EFFECTIVE_CONNECTION_TYPE_UNKNOWN);
229 230
230 mTestFramework.mCronetEngine.shutdown(); 231 mTestFramework.mCronetEngine.shutdown();
231 } 232 }
232 } 233 }
OLDNEW
« no previous file with comments | « chrome/browser/resources/net_internals/quic_view.html ('k') | components/cronet/url_request_context_config.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698