Beispiel #1
0
 public void testLoad() throws CoreException {
   WARProductModel model = new WARProductModel();
   String separator = "/";
   ClassLoader classLoader = getClass().getClassLoader();
   String fileName = separator + "test.warproduct";
   model.load(classLoader.getResourceAsStream(fileName), false);
   IWARProduct product = (IWARProduct) model.getProduct();
   String webXmlPath = product.getWebXml().toString();
   assertEquals(
       separator + "test.rap" + separator + "WEB-INF" + separator + "web.xml", webXmlPath);
   String launchIniPath = product.getLaunchIni().toString();
   assertEquals(
       separator
           + "test.rap"
           + separator
           + "WEB-INF"
           + separator
           + "eclipse"
           + separator
           + "launch.ini",
       launchIniPath);
   String libJarPath = product.getLibraries()[0].toString();
   assertEquals(separator + "test.rap" + separator + "lib.jar", libJarPath);
 }