use of com.dtflys.test.http.model.JsonTestUser2 in project forest by dromara.
the class TestPostClient method testPostJsonObjectWithLog_content_noStatus2.
@Test
public void testPostJsonObjectWithLog_content_noStatus2() {
server.enqueue(new MockResponse().setBody(EXPECTED));
ForestLogHandler logHandler = configuration.getLogHandler();
ForestLogger logger = Mockito.mock(ForestLogger.class);
logHandler.setLogger(logger);
JsonTestUser2 user = new JsonTestUser2();
user.setUsername("foo");
assertThat(postClient.postJsonObjectWithLog_content_noStatus(user)).isNotNull().isEqualTo(EXPECTED);
Mockito.verify(logger).info("[Forest] Response Content:\n\t" + EXPECTED);
}
Aggregations