* Switch to a Builder for mockwebserver3.MockResponse
* Migrate lots of tests to MockResponse.Builder
* Improve some code style
* Follow naming conventions in MockResponse.Builder
* Apply side-effects for inTunnel=true
* Update the API
I attempted to do a literal translation as much as possible.
Subprojects now need plugins to be configured directly so they
can use the appropriate syntax.
Also rename okhttp3.mockwebserverwrapper to okhttp3.mockwebserver
Directories are not renamed to minimize the git diff. That'll follow
in a separate commit.
Most users of the API are not impacted. The ones that are:
- CallTest subclasses QueueDispatcher
- DuplexTest uses duplex APIs
- HttpOverHttp2Test subclasses QueueDispatcher
This is part 2 of the plan described here:
https://github.com/square/okhttp/pull/6326
This removes a bunch of low-value stuff from the pom.xml files:
- name
- description
- licence distribution ('repo')
- developers clause
- test dependencies
I don't think any of this will be missed, and it shrinks the pom.xml
file to the minimal set of useful stuff.
This also causes us to publish a gradle .module file. This is the
motivation for this change. It'll allow us to ship a Gradle platform,
which is a more capable than a Maven BOM.
The new ktlint sorts imports which makes this diff large.
The new japicmp ignores 'final' modifier changes in final classes.
We adopt the Google style for checkstyle.xml.
Okio readByteString() now uses segments more aggressively, so we
need to mitigate that to avoid tracking those segments in a test.