*/
public class ServiceMapParserTest extends Assert {
@Test
public void testParse() throws Exception {
ServiceMapParser serviceMapParser = new ServiceMapParser();
String xmlString = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" +
"<container>" +
"<service id=\"adrienbrault\" class=\"AdrienBrault\\Awesome\"/>" +
"<service id=\"secret\" class=\"AdrienBrault\\Secret\" public=\"false\"/>" +
"<service id=\"translator\" alias=\"adrienbrault\"/>" +
"</container>";
ServiceMap serviceMap = serviceMapParser.parse(new ByteArrayInputStream(xmlString.getBytes()));
assertTrue(serviceMap instanceof ServiceMap);
assertEquals("\\AdrienBrault\\Awesome", serviceMap.getMap().get("adrienbrault"));
assertEquals("\\AdrienBrault\\Awesome", serviceMap.getPublicMap().get("adrienbrault"));