### Question:
PostmanService { String prettyPrint(String fileContent, String contentType) { if (MediaType.APPLICATION_JSON_VALUE.equals(contentType) || StringUtils.startsWith(contentType, MediaType.APPLICATION_JSON_VALUE + ";")) { try { Object json = objectMapper.readValue(fileContent, Object.class); return objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(json); } catch (@SuppressWarnings( "squid:S1166") IOException e) { } } return fileContent; }  void parse(JsonParser parser, NewmanParsingResult result); List<ExecutedScenario> postProcess(Run run, NewmanParsingResult result, String newmanReportPath, AtomicInteger requestPosition); void deleteTempFiles(NewmanParsingResult newmanParsingResult); static final String FOLDER_DELIMITER; }### Answer:
@Test public void prettyPrint_should_indent_application_json() { assertThat(cut.prettyPrint(JSON_RAW, "application/json")).isEqualTo(JSON_INDENTED); }
@Test public void prettyPrint_should_indent_application_json_with_charset() { assertThat(cut.prettyPrint(JSON_RAW, "application/json; charset=iso-8859-1")).isEqualTo(JSON_INDENTED); }
@Test public void prettyPrint_should_not_indent_other_mime_types() { assertThat(cut.prettyPrint(JSON_RAW, "other/mime-type")).isEqualTo(JSON_RAW); }
@Test public void prettyPrint_should_not_indent_malformed_json() { assertThat(cut.prettyPrint("{malformed", "application/json")).isEqualTo("{malformed"); }