History log of /external/volley/src/test/java/com/android/volley/toolbox/BasicNetworkTest.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
dd439dcb42093fde4452e320f3a9c4bfa2066def 16-Oct-2015 Jeff Davidson <jpd@google.com> Retry more errors in Volley's BasicNetwork.

Always retry I/O errors while reading the HTTP response entity.
Furthermore, if a client opts in, retry HTTP 500 errors indicating
something went wrong on the server.

This resolves a longstanding TODO to only throw a ServerError on 5xx
errors by adding a ClientError for 4xx errors. For backwards
compatibility, this extends ServerError.

Note that Volley already may retry a request that reached the server
if the connection times out, which means that lack of idempotency
shouldn't be a concern here if it wasn't already. But if we wanted to
be even safer, we could require clients to opt into the additional
retry cases, at the cost of a somewhat more polluted API.

Add unit tests for most failure scenarios.

Bug: 23152983
Change-Id: I92cf35c66ccf98a1682adf41654afeb8634911db
/external/volley/src/test/java/com/android/volley/toolbox/BasicNetworkTest.java
b9b8dc3d98fb1a8c3f02c2c2fcc18cbd344c05cb 29-Nov-2014 Ficus Kirkpatrick <ficus@android.com> Migrate from Gradle to Maven.

- Restructure source to src/{main,test} style
- Add pom.xml and update Android.mk
- Migrate all tests to JUnit4 and Robolectric
- RequestQueueTest is currently @Ignored as fixing it will
involve more extensive refactoring.
- Main library still builds in Gradle; tests do not

Change-Id: I1edc53bb1a54f64d3e806e4572901295ef63e2ca
/external/volley/src/test/java/com/android/volley/toolbox/BasicNetworkTest.java