Class JsonContent
java.lang.Object
org.springframework.test.json.JsonContent
- All Implemented Interfaces:
- org.assertj.core.api.AssertProvider<JsonContentAssert>
public final class JsonContent
extends Object
implements org.assertj.core.api.AssertProvider<JsonContentAssert>
- Since:
- 6.2
- Author:
- Phillip Webb, Diego Berrueta
- 
Constructor SummaryConstructorsConstructorDescriptionJsonContent(String json) Create a newJsonContentinstance.JsonContent(String json, @Nullable HttpMessageContentConverter contentConverter) Create a newJsonContentinstance with the message converter to use to deserialize content.
- 
Method Summary
- 
Constructor Details- 
JsonContentCreate a newJsonContentinstance with the message converter to use to deserialize content.- Parameters:
- json- the actual JSON content
- contentConverter- the content converter to use
 
- 
JsonContentCreate a newJsonContentinstance.- Parameters:
- json- the actual JSON content
 
 
- 
- 
Method Details- 
assertThatUse AssertJ'sassertThatinstead.- Specified by:
- assertThatin interface- org.assertj.core.api.AssertProvider<JsonContentAssert>
 
- 
getJsonReturn the actual JSON content string.
- 
toString
 
-