Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
-
1.3RC1
Description
The introduction of PropertiesConfigurationLayout broke the saving of in memory created PropertesConfiguration.
This piece of code will yield empt saved file:
PropertiesConfiguration pc = new PropertiesConfiguration();
pc.addProperty("string", "value1");
pc.save("testsave.properties");
The problem is that no PropertiesConfigurationLayout is created and EVENT_ADD_PROPERTY is lost.
Then when saving, an empty PropertiesConfigurationLayout is created and nothing is saved in output file.
Added creation of PropertiesConfigurationLayout to PropertiesConfiguration() contructor, changed setLayout() to enforce that only one layout per PropertiesConfiguration must exist and added a testcase for this condition.