@Test
public void testReadDictionary_dotPropertiesXml() throws Exception {

    final Map<String, Object> expectProperties = new HashMap<>();
    expectProperties.put("foo", "bar");
    expectProperties.put("foos", "bar,bar,bar");
    expectProperties.put("ones", "1,1,1");
    expectProperties.put("nothing", "");
    ByteArrayOutputStream propsXmlBytes = new ByteArrayOutputStream();
    Properties srcPropertiesXml = new Properties();
    srcPropertiesXml.putAll(expectProperties);
    srcPropertiesXml.storeToXML(propsXmlBytes, "generated by test", "UTF-8");
    final String dotPropertiesXml = new String(propsXmlBytes.toByteArray(), StandardCharsets.UTF_8);
    final Map<String, Object> simplePropertiesXml = DefaultSlingSimulator.readDictionary(
            new ByteArrayInputStream(dotPropertiesXml.getBytes(StandardCharsets.UTF_8)), "simple.xml");
    checkExpectedProperties(expectProperties, simplePropertiesXml);
}