Examples of JarHelper


Examples of org.apache.jetspeed.util.JarHelper

    }
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

    }
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

    }
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

   
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

        dstDemoWarChannel.transferFrom(srcDemoWarChannel, 0, srcDemoWarChannel.size());
        srcDemoWarChannel.close();
        dstDemoWarChannel.close();
       
        // Make sure the demo.war that will trigger redeploy has a larger portlet.xml then the current one
        JarHelper rdDemoWar = new JarHelper(demoWar, true);
        assertTrue(new File(rdDemoWar.getRootDirectory(), "WEB-INF/portlet.xml").length() > beforeSize);
       
        // Need to slow it down so the timestamp check works
        Thread.sleep(500);
        demoWar.setLastModified(System.currentTimeMillis());
        autoDeployment.fireRedeploymentEvent();
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

            fsh = new DirectoryHelper(deploymentObject);
        }
        else if(verifyExtension(deploymentObject))
        {
            boolean deleteOnClose = !deploymentObject.getName().startsWith("jetspeed-");          
            fsh = new JarHelper(deploymentObject, deleteOnClose);
        }
        else
        {
            throw new FileNotDeployableException("File type for "+deploymentObject.getName()+" is not supported by StandardDeploymentObject.");
        }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

    }
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

    }
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.jetspeed.util.JarHelper

    }
    public void testFileSystemHelperOnWar() throws Exception
    {
        File demoApp = new File(deploySrc, "demo.war");
          
        JarHelper jarHelper = new JarHelper(demoApp, true);
        File rootDirectory = jarHelper.getRootDirectory();
        File webXml = new File(rootDirectory, "WEB-INF/web.xml");
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertFalse(webXml.exists());
       
        // Test for keeping jar temp files around
        jarHelper = new JarHelper(demoApp, false);
        assertTrue(webXml.exists());
        jarHelper.close();         
        assertTrue(webXml.exists());
    }
View Full Code Here

Examples of org.apache.xmlbeans.impl.common.JarHelper

                // jar classes and .xsb
                if (result && outputJar != null)
                {
                    try
                    {
                        new JarHelper().jarDir(classesDir, outputJar);
                    }
                    catch (IOException e)
                    {
                        System.err.println("IO Error " + e);
                        result = false;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.