History log of /external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/SocksProxy.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
231519b0362806e99f234e4bd136d04627605f73 21-Jun-2016 Tobias Thierer <tobiast@google.com> Apply upstream commit: Let SocksProxy use the same definition of localhost as MockWebServer.

This fixes SocksProxyTest failing on some systems. The problem was that
MockWebServer is listening on InetAddress.getByName("localhost") but
SocksProxy was trying to connect to InetAddress.getLoopbackAddress().
This is not guaranteed to work, for example on recent AOSP, "localhost"
resolves to 127.0.0.1 but getLoopbackAddress() is ::1 (IPv6).

This CL makes the simplest change to make the two consistent so that
SocksProxyTest passes. In the long run, OkHttp may want to consider
using getLoopbackAddress().getHostname() everywhere instead of hard
coding the hostname "localhost" at all.

(cherry picked from upstream commit df73a7e98e8450813325d28458b6bdd4b8b11791)

Change-Id: Ib0e860ea1a8646c4e2b9739974486159294a8fdc
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/SocksProxy.java
6c251e20f00c7574b217bd4351ac81666f574380 24-Jun-2016 Tobias Thierer <tobiast@google.com> Update OkHttp to 2.7.5 and advance okio by one commit.

This brings OkHttp and okio exactly in line with upstream commits
with no local changes.

Corresponding upstream commits:
okhttp:6e236ce3b80f21369dc544f0e1053ff71be8689b (= parent-2.7.5)
okio: 02481cc0cc84bc92e3eab6d5212a226496f56a7e

The okio commit differs from the one in the previous pull from
Sep 2015 (AOSP commit 71b9f47b26fb57ac3e436a19519c6e3ec70e86eb)
only by a single upstream commit, the switch to 8 KiB segments.
That commit was previously cherry-picked in AOSP. This CL will
temporarily revert the AOSP changes to okio, but those
AOSP changes to okio will be reapplied in the subsequent CL.

Compilation and tests do not pass after this CL, they will only
pass at the end of the chain of 11 CLs going in at the same time.
9 of these 11 CLs are in external/okhttp, the others affect
libcore and frameworks/base.

Details of behavioural changes introduced by this upgrade are at:
https://docs.google.com/document/d/19PF3Exd_q32gAGCiRFWRf0Pq_xrIWs-cRViHkFTxJg8/edit

This CL includes files that are not used in Android, such as
- top level dot files (.travis.yml etc.)
- subdirectories okurl, okhttp-apache, samples, which aren't used
- tests in okhttp-hpacktests, okhttp-ws-tests that aren't run
or test functionality that we aren't used

Test: I've run the following tests *at the end* of the chain of
commits, in cts-tradefed:
1.) run cts -p android.core.tests.libcore.package.harmony_java_net
2.) run cts -c libcore.java.net.URLConnectionTest
3.) run cts -p android.core.tests.libcore.package.okhttp
4.) run cts -p android.core.tests.libcore.package.libcore

1.-3.) all passed
4.) had 24 unrelated failures per b/29496407 and b/29744850

Change-Id: Id798d6cf49fa4a7a4ab8ae3b699a38104bf42db3
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/SocksProxy.java
e78f117bcbd6b57d783737107f445ef75ecb474a 20-Jan-2015 Neil Fuller <nfuller@google.com> Pull latest OkHttp code from upstream

okio:

okio is now managed upstream as a separate project but has
been included here as a sub directory: the okio version here
is intended only for use with OkHttp.
okio is synced to upstream commit
82358df7f09e18aa42348836c614212085bbf045.
See okio/README.android for local changed needed to make it
compile.

okhttp:

This is effectively an upgrade from a snapshot close to
OkHttp 1.5 with Android additions to a snapshot close to
OkHttp 2.2.
okhttp was synced to upstream commit
0a197466608681593cc9be9487965a0b1d5c244c
See README.android for local changes needed to make it
compile.

Most of the old Android changes have been pushed upstream
and other upstream changes have been made to keep OkHttp
working on Android.

TLS fallback changes have not been upstreamed yet:
bcce0a3d26d66d33beb742ae2adddb3b7db5ad08
ede2bf1af0917482da8ccb7b048130592034253d

This means that some CTS tests will start to fail. A later
commit will fix those changes when it has been accepted
upstream.

There are associated changes in libcore and frameworks/base.

Change-Id: I0a68b27b1ec7067be452671bc591edfd84e310f2
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/SocksProxy.java