StandardWriterTests Class — spring-boot Architecture
Architecture documentation for the StandardWriterTests class in JsonWriterTests.java from the spring-boot codebase.
Entity Profile
Source Code
core/spring-boot/src/test/java/org/springframework/boot/json/JsonWriterTests.java lines 210–236
@Nested
class StandardWriterTests {
@Test
void whenPrimitive() {
assertThat(write(null)).isEqualTo("null");
assertThat(write(123)).isEqualTo("123");
assertThat(write(true)).isEqualTo("true");
assertThat(write("test")).isEqualTo(quoted("test"));
}
@Test
void whenMap() {
assertThat(write(Map.of("spring", "boot"))).isEqualTo("""
{"spring":"boot"}""");
}
@Test
void whenArray() {
assertThat(write(new int[] { 1, 2, 3 })).isEqualTo("[1,2,3]");
}
private <T> String write(@Nullable T instance) {
return JsonWriter.standard().writeToString(instance);
}
}
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free