ByteArrayInputStream is = new ByteArrayInputStream(str.getBytes());
XMLStreamReader reader = inputFactory.createXMLStreamReader(is);
reader.next();
OSGiImplementationImpl osgiImpl = (OSGiImplementationImpl)staxProcessor.read(reader);
assertEquals(osgiImpl.getBundleSymbolicName(), "OSGiTestService");
assertEquals(osgiImpl.getBundleVersion(), "2.0.0");
assertTrue(osgiImpl.getImports().length == 2);
assertEquals(osgiImpl.getImports()[0], "import1.jar");
assertEquals(osgiImpl.getImports()[1], "import2.jar");
}