Skip to content

Commit

Permalink
Upgraded HttpClient to version 5.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ok2c committed Nov 25, 2024
1 parent e740e06 commit be439ea
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
3 changes: 1 addition & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ buildscript {
}

val versions = mapOf(
"httpclient" to "5.3.1",
"httpcore" to "5.2.5",
"httpclient" to "5.4.1",
"assertj" to "3.26.3"
)

Expand Down
8 changes: 3 additions & 5 deletions httpclient-android/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ dependencies {
val versions: Map<String, String> by project.extra

api("org.apache.httpcomponents.client5:httpclient5:${versions["httpclient"]}")
api("org.apache.httpcomponents.core5:httpcore5:${versions["httpcore"]}")
api("org.apache.httpcomponents.core5:httpcore5-h2:${versions["httpcore"]}")
androidTestImplementation("org.assertj:assertj-core:${versions["assertj"]}")
androidTestImplementation("com.android.support.test:runner:1.0.2")
androidTestImplementation("com.android.support.test.espresso:espresso-core:3.0.2")
Expand All @@ -64,9 +62,9 @@ tasks.register<Javadoc>("androidJavadocs") {
stdOptions.links(
"http://docs.oracle.com/javase/7/docs/api/",
"http://developer.android.com/reference/",
"https://hc.apache.org/httpcomponents-core-5.1.x/current/httpcore5/apidocs/",
"https://hc.apache.org/httpcomponents-core-5.1.x/current/httpcore5-h2/apidocs/",
"https://hc.apache.org/httpcomponents-client-5.1.x/current/httpclient5/apidocs/")
"https://hc.apache.org/httpcomponents-core-5.3.x/current/httpcore5/apidocs/",
"https://hc.apache.org/httpcomponents-core-5.3.x/current/httpcore5-h2/apidocs/",
"https://hc.apache.org/httpcomponents-client-5.4.x/current/httpclient5/apidocs/")
}

tasks.register<Jar>("androidJavadocsJar") {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ class ClassicHttpBinIntegrationTest {
.setPath("/bytes/20000")
.build();
val message = client.execute(request) { response ->
Message(response, EntityUtils.toString(response.entity))
Message(response, EntityUtils.toByteArray(response.entity))
}
Assertions.assertThat(message.head.code).isEqualTo(HttpStatus.SC_OK)
Assertions.assertThat(message.body).hasSize(20000)
Expand Down

0 comments on commit be439ea

Please sign in to comment.