}
}
private static Map getPluginDefaults(final Element elementToAlter) {
final PluginRegistry pluginsRegistry = PluginRegistry.createRegistry();
final Map pluginDefaults = new HashMap();
// note: the map returned here is "unmodifiable"
pluginDefaults.putAll(pluginsRegistry.getDefaultProperties(elementToAlter.getName()));
if (pluginDefaults.size() == 0) { // maybe we're in a unit test
// @todo Remove this kludge when we figure out how to make PluginRegistry work in unit test
LOG.warn("Unit Test kludge for plugin default values. "
+ "Should happen only if no default plugin settings exist OR during unit tests.");