Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,46 @@ public void testValueExtractionFromSystemPropertiesWithMissingProject() throws E
assertEquals("value", value);
}

public void testValueExtractionOfMissingPrefixedProperty() throws Exception {
Properties executionProperties = new Properties();

ExpressionEvaluator ee = createExpressionEvaluator(null, null, executionProperties);

Object value = ee.evaluate("prefix-${PPEET_nonexisting_p_property}");

assertEquals("prefix-${PPEET_nonexisting_p_property}", value);
}

public void testValueExtractionOfMissingSuffixedProperty() throws Exception {
Properties executionProperties = new Properties();

ExpressionEvaluator ee = createExpressionEvaluator(null, null, executionProperties);

Object value = ee.evaluate("${PPEET_nonexisting_s_property}-suffix");

assertEquals("${PPEET_nonexisting_s_property}-suffix", value);
}

public void testValueExtractionOfMissingPrefixedSuffixedProperty() throws Exception {
Properties executionProperties = new Properties();

ExpressionEvaluator ee = createExpressionEvaluator(null, null, executionProperties);

Object value = ee.evaluate("prefix-${PPEET_nonexisting_ps_property}-suffix");

assertEquals("prefix-${PPEET_nonexisting_ps_property}-suffix", value);
}

public void testValueExtractionOfMissingProperty() throws Exception {
Properties executionProperties = new Properties();

ExpressionEvaluator ee = createExpressionEvaluator(null, null, executionProperties);

Object value = ee.evaluate("${PPEET_nonexisting_property}");

assertNull(value);
}

public void testValueExtractionFromSystemPropertiesWithMissingProject_WithDotNotation() throws Exception {
String sysprop = "PPEET.sysprop2";

Expand Down