Source:
<code>public static TestReport from(Entity entity) { checkNotNull(entity, "'entity' parameter cannot be null"); checkArgument(TEST_REPORT.equals(entity.getKind()), "'entity' parameter wrong kind"); final List<Test> failedTests = new ArrayList<>(); try { final JSONArray jsonArray = new JSONArray(new JSONTokener(((Text) entity.getProperty("failedTests")).getValue())); for (int i = 0; i < jsonArray.length(); i++) { final Test test = Test.valueOf(jsonArray.getJSONObject(i)); failedTests.add(test); } } catch (JSONException e) { throw new RuntimeException(e); } final List<Test> ignoredTests = new ArrayList<>(); try { final JSONArray jsonArray = new JSONArray(new JSONTokener(((Text) entity.getProperty("ignoredTests")).getValue())); for (int i = 0; i < jsonArray.length(); i++) { final Test test = Test.valueOf(jsonArray.getJSONObject(i)); ignoredTests.add(test); } } catch (JSONException e) { throw new RuntimeException(e); <START> } catch (NullPointerException e) { <END> log.info(String.format("Ignored test do not have detailed information : %s [%s]", entity.getProperty("buildTypeId"), entity.getProperty("buildId"))); } return new TestReport( (String) entity.getProperty("buildTypeId"), ((Long) entity.getProperty("buildId")).intValue(), (Date) entity.getProperty("buildDate"), ((Long) entity.getProperty("buildDuration")), ((Long) entity.getProperty("numberOfPassedTests")).intValue(), ((Long) entity.getProperty("numberOfIgnoredTests")).intValue(), ((Long) entity.getProperty("numberOfFailedTests")).intValue(), failedTests, ignoredTests ); }</code><technical_language>Uh, catching NPE ... is other get this</technical_language>

Target:
public static TestReport from(Entity entity) { checkNotNull(entity, "'entity' parameter cannot be null"); checkArgument(TEST_REPORT.equals(entity.getKind()), "'entity' parameter wrong kind"); final List<Test> failedTests = new ArrayList<>(); try { final JSONArray jsonArray = new JSONArray(new JSONTokener(((Text) entity.getProperty("failedTests")).getValue())); for (int i = 0; i < jsonArray.length(); i++) { final Test test = Test.valueOf(jsonArray.getJSONObject(i)); failedTests.add(test); } } catch (JSONException e) { throw new RuntimeException(e); } final List<Test> ignoredTests = new ArrayList<>(); try { final Text ignoredTestsEntity = (Text) entity.getProperty("ignoredTests"); if (ignoredTestsEntity != null) { final JSONArray jsonArray = new JSONArray(new JSONTokener(ignoredTestsEntity.getValue())); for (int i = 0; i < jsonArray.length(); i++) { final Test test = Test.valueOf(jsonArray.getJSONObject(i)); ignoredTests.add(test); } } else { log.info(String.format("Ignored test do not have detailed information : %s [%s]", entity.getProperty("buildTypeId"), entity.getProperty("buildId"))); } } catch (JSONException e) { throw new RuntimeException(e); } return new TestReport( (String) entity.getProperty("buildTypeId"), ((Long) entity.getProperty("buildId")).intValue(), (Date) entity.getProperty("buildDate"), ((Long) entity.getProperty("buildDuration")), ((Long) entity.getProperty("numberOfPassedTests")).intValue(), ((Long) entity.getProperty("numberOfIgnoredTests")).intValue(), ((Long) entity.getProperty("numberOfFailedTests")).intValue(), failedTests, ignoredTests ); }