Examples of JettyWebAppType


Examples of org.apache.geronimo.xbeans.geronimo.jetty.JettyWebAppType

    private WebAppDConfigBean webAppBean;

    public WebAppDConfigRoot(DDBeanRoot ddBean) {
        super(ddBean, JettyWebAppDocument.Factory.newInstance());
        JettyWebAppType webApp = getWebAppDocument().addNewWebApp();
        replaceWebAppDConfigBean(webApp);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    }

    public void testContents() throws Exception {
        URL resourcePlan = classLoader.getResource("plans/plan1.xml");
        assertTrue(resourcePlan != null);
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(new File(resourcePlan.getFile()), null, true, null, null);
        assertEquals(1, jettyWebApp.getResourceRefArray().length);
//        assertEquals(4, jettyWebApp.getSecurity().getRoleMappings().getRoleArray().length);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    }

    public void testMoveSecurity1() throws Exception {
        URL resourcePlan = classLoader.getResource("plans/plan1A.xml");
        assertTrue(resourcePlan != null);
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(new File(resourcePlan.getFile()), null, true, null, null);
        assertEquals(1, jettyWebApp.getResourceRefArray().length);
//        assertEquals(4, jettyWebApp.getSecurity().getRoleMappings().getRoleArray().length);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    }

    public void testMoveSecurity2() throws Exception {
        URL resourcePlan = classLoader.getResource("plans/plan1B.xml");
        assertTrue(resourcePlan != null);
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(new File(resourcePlan.getFile()), null, true, null, null);
        assertEquals(1, jettyWebApp.getResourceRefArray().length);
//        assertEquals(4, jettyWebApp.getSecurity().getRoleMappings().getRoleArray().length);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    }

    public void testMoveSecurity3() throws Exception {
        URL resourcePlan = classLoader.getResource("plans/plan1C.xml");
        assertTrue(resourcePlan != null);
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(new File(resourcePlan.getFile()), null, true, null, null);
//        assertEquals(4, jettyWebApp.getSecurity().getRoleMappings().getRoleArray().length);
//        log.debug(jettyWebApp.xmlText());
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    }

    public void testOldFormat() throws Exception {
        URL resourcePlan = classLoader.getResource("plans/plan2.xml");
        assertTrue(resourcePlan != null);
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(new File(resourcePlan.getFile()), null, true, null, null);
        assertEquals(1, jettyWebApp.getResourceRefArray().length);
//        assertEquals(4, jettyWebApp.getSecurity().getRoleMappings().getRoleArray().length);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    public void testOldFormatExploded() throws Exception {
        URL war = classLoader.getResource("deployables/war5");
        assertTrue(war != null);
        UnpackedJarFile moduleFile = new UnpackedJarFile(new File(war.getFile()));
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(null, moduleFile, true, null, null);
        moduleFile.close();
        assertEquals(1, jettyWebApp.getResourceRefArray().length);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

    public void XtestOldFormatPackaged() throws Exception {
        URL war = classLoader.getResource("deployables/war6.war");
        assertTrue(war != null);
        JarFile moduleFile = new JarFile(new File(war.getFile()));
        JettyWebAppType jettyWebApp = builder.getJettyWebApp(null, moduleFile, true, null, null);
        moduleFile.close();
        assertEquals(1, jettyWebApp.getResourceRefArray().length);
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

        assertEquals(1, jettyWebApp.getResourceRefArray().length);
    }

    public void testConstructPlan() throws Exception {
        JettyWebAppDocument jettyWebAppDoc = JettyWebAppDocument.Factory.newInstance();
        JettyWebAppType webApp = jettyWebAppDoc.addNewWebApp();
        addEnvironment(webApp);
        GerResourceRefType ref = webApp.addNewResourceRef();
        ref.setRefName("ref");
        ref.setResourceLink("target");

        XmlBeansUtil.validateDD(webApp);
        log.debug(webApp.toString());
    }
View Full Code Here

Examples of org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType

     * @throws Exception
     */
    public void testContextRootWithPlanAndContextSet() throws Exception {

        JettyWebAppDocument jettyWebAppDoc = JettyWebAppDocument.Factory.newInstance();
        JettyWebAppType webApp = jettyWebAppDoc.addNewWebApp();
        addEnvironment(webApp);
        webApp.setContextRoot("myContextRoot");

        URL war = classLoader.getResource("deployables/war2.war");
        assertTrue(war != null);
        JarFile dummyFile = new JarFile(new File(war.getFile()));

        webApp = builder.getJettyWebApp(webApp, dummyFile, true, null, null);

        assertEquals("myContextRoot", webApp.getContextRoot());

    }
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.