Skip to content

Commit e5b3478

Browse files
LucasEbysrinath-ctds
authored andcommitted
[fix][test] Fixed ResponseBody Check in Test Helper (apache#24872)
(cherry picked from commit 2463254) (cherry picked from commit f71ff1e)
1 parent 56275ea commit e5b3478

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pulsar-io/http/src/test/java/org/apache/pulsar/io/http/HttpSinkTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
2222
import static com.github.tomakehurst.wiremock.client.WireMock.configureFor;
2323
import static com.github.tomakehurst.wiremock.client.WireMock.equalTo;
24+
import static com.github.tomakehurst.wiremock.client.WireMock.equalToJson;
2425
import static com.github.tomakehurst.wiremock.client.WireMock.post;
2526
import static com.github.tomakehurst.wiremock.client.WireMock.postRequestedFor;
2627
import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
@@ -424,7 +425,7 @@ public Optional<Long> getIndex() {
424425
httpSink.write(record);
425426

426427
verify(postRequestedFor(urlEqualTo("/"))
427-
.withRequestBody(equalTo(responseBody))
428+
.withRequestBody(equalToJson(responseBody))
428429
.withHeader("Content-Type", equalTo("application/json"))
429430
.withHeader("header-name", equalTo("header-value"))
430431
.withHeader("PulsarTopic", equalTo("test-topic"))

0 commit comments

Comments
 (0)