### Question:
BaseDTO implements Serializable { @Override public String toString() { try { return GenieObjectMapper.getMapper().writeValueAsString(this); } catch (final JsonProcessingException ioe) { return ioe.getLocalizedMessage(); } } BaseDTO(final Builder builder); Optional<String> getId(); Optional<Instant> getCreated(); Optional<Instant> getUpdated(); @Override String toString();  }### Answer:
@Test void canCreateValidJsonString() { final Application application = new Application.Builder( UUID.randomUUID().toString(), UUID.randomUUID().toString(), UUID.randomUUID().toString(), ApplicationStatus.ACTIVE ).build(); final String json = application.toString(); Assertions.assertThatCode(() -> GenieObjectMapper.getMapper().readTree(json)).doesNotThrowAnyException(); }