@Test @Parameters(method = "useRegexReplacement") public void testPerformReplacementWithInvalidReplacement(boolean regex) throws IOException { Properties actualProperties = build("key1", "value1", "key2", "value2"); List<ReplacementProperty> replacementProperties = new ArrayList<>(); replacementProperties.add(new ReplacementProperty("key1", null, null, null, regex, false, null)); propertiesReplacer.performReplacement(actualProperties, replacementProperties); }
public void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties) { if ((replacementProperties != null) && (properties != null)) { for (ReplacementProperty replacementProperty: replacementProperties) { String propertyKey = replacementProperty.getProperty(); if (propertyKey == null) { performReplacementOnAllGeneratedProperties(properties, replacementProperty); } else { performReplacementOnSingleProperty(properties, replacementProperty, propertyKey); } } } }
PropertiesReplacer { public void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties) { if ((replacementProperties != null) && (properties != null)) { for (ReplacementProperty replacementProperty: replacementProperties) { String propertyKey = replacementProperty.getProperty(); if (propertyKey == null) { performReplacementOnAllGeneratedProperties(properties, replacementProperty); } else { performReplacementOnSingleProperty(properties, replacementProperty, propertyKey); } } } } }
PropertiesReplacer { public void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties) { if ((replacementProperties != null) && (properties != null)) { for (ReplacementProperty replacementProperty: replacementProperties) { String propertyKey = replacementProperty.getProperty(); if (propertyKey == null) { performReplacementOnAllGeneratedProperties(properties, replacementProperty); } else { performReplacementOnSingleProperty(properties, replacementProperty, propertyKey); } } } } PropertiesReplacer(LoggerBridge log, PluginParameterExpressionEvaluator expressionEvaluator); }
PropertiesReplacer { public void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties) { if ((replacementProperties != null) && (properties != null)) { for (ReplacementProperty replacementProperty: replacementProperties) { String propertyKey = replacementProperty.getProperty(); if (propertyKey == null) { performReplacementOnAllGeneratedProperties(properties, replacementProperty); } else { performReplacementOnSingleProperty(properties, replacementProperty, propertyKey); } } } } PropertiesReplacer(LoggerBridge log, PluginParameterExpressionEvaluator expressionEvaluator); void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties); }
PropertiesReplacer { public void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties) { if ((replacementProperties != null) && (properties != null)) { for (ReplacementProperty replacementProperty: replacementProperties) { String propertyKey = replacementProperty.getProperty(); if (propertyKey == null) { performReplacementOnAllGeneratedProperties(properties, replacementProperty); } else { performReplacementOnSingleProperty(properties, replacementProperty, propertyKey); } } } } PropertiesReplacer(LoggerBridge log, PluginParameterExpressionEvaluator expressionEvaluator); void performReplacement(Properties properties, List<ReplacementProperty> replacementProperties);  }