SlingJcrInstaller implements ProgressCheckFactory { @Override public ProgressCheck newInstance(final JsonObject config) { final List<String> rootPaths = JavaxJson.optArray(config, keys().rootPaths()) .map(JavaxJson::mapArrayOfStrings) .orElse(DEFAULT_ROOT_PATHS); final int maxDepth = config.getInt(keys().maxDepth(), DEFAULT_MAX_DEPTH); return new Check(rootPaths, maxDepth); }  static JsonKeys keys(); @Override ProgressCheck newInstance(final JsonObject config);  }
@Test public void testNullSafety() throws Exception { new SlingJcrInstaller().newInstance(obj().get()) .importedPath(null, null, null, null); }
@Test public void testSetSilencedSafety() { ((SilenceableCheck) new SlingJcrInstaller().newInstance(obj().get())).setSilenced(true); }