Package de.odysseus.calyxo.base.test

Examples of de.odysseus.calyxo.base.test.TestModuleContext


  protected void setUp() throws ServletException {
    pageContext = new TestPageContext();
    HttpServletRequest request = (HttpServletRequest)pageContext.getRequest();
    // configure test module
    module = new TestModuleContext("test", pageContext.getServletContext());
    // configure module container
    ServletContext context = request.getSession().getServletContext();
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    group.add(module);
    // select module
View Full Code Here


    request = new TestRequest();
    // configure module container
    ServletContext context = request.getSession().getServletContext();
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    // configure test module
    module = new TestModuleContext("test", context);
    group.add(module);
    group.setTestModuleContext(request, module);

    PanelsService service = new PanelsService();
    String xml = "/" + getClass().getName().replace('.', '/') + ".xml";
View Full Code Here

  }

  protected void setUp() throws ServletException {
    pageContext = new TestPageContext(request);
    // configure test module
    module = new TestModuleContext("test", pageContext.getServletContext());
    // configure module container
    ServletContext context = request.getSession().getServletContext();
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    group.add(module);
    // select module
View Full Code Here

    HttpServletRequest request = (HttpServletRequest)pageContext.getRequest();
    // configure module container
    ServletContext context = request.getSession().getServletContext();
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    // configure test modules
    module1 = new TestModuleContext("test1", pageContext.getServletContext());
    group.add(module1);
    module2 = new TestModuleContext("test2", pageContext.getServletContext());
    group.add(module2);
    group.setTestModuleContext(request, module1);
  }
View Full Code Here

  }

  public void test1() throws Exception {
    String xml = "/" + getClass().getName().replace('.', '/') + "1.xml";
    URL url = getClass().getResource(xml);
    ModuleContext context = new TestModuleContext("test");
    PanelsRootConfigParser parser = new PanelsRootConfigParser(context);
    PanelsRootConfig root = parser.parse(new URL[]{url});
//    System.out.println(root);
    PanelConfig foo = root.findPanelConfig("foo", null);
    assertNotNull(foo);
View Full Code Here

  public void test2() throws Exception {
    String xml1 = "/" + getClass().getName().replace('.', '/') + "1.xml";
    URL url1 = getClass().getResource(xml1);
    String xml2 = "/" + getClass().getName().replace('.', '/') + "2.xml";
    URL url2 = getClass().getResource(xml2);
    ModuleContext context = new TestModuleContext("test");
    PanelsRootConfigParser parser = new PanelsRootConfigParser(context);
    PanelsRootConfig root = parser.parse(new URL[]{url1,url2});
//    System.out.println(root);
    PanelConfig foo = root.findPanelConfig("foo", null);
    assertNotNull(foo);
View Full Code Here

    URL url1 = getClass().getResource(xml1);
    String xml2 = "/" + getClass().getName().replace('.', '/') + "2.xml";
    URL url2 = getClass().getResource(xml2);
    String xml3 = "/" + getClass().getName().replace('.', '/') + "3.xml";
    URL url3 = getClass().getResource(xml3);
    ModuleContext context = new TestModuleContext("test");
    PanelsRootConfigParser parser = new PanelsRootConfigParser(context);
    PanelsRootConfig root = parser.parse(new URL[]{url1,url2,url3});
//    System.out.println(root);
    PanelConfig foo = root.findPanelConfig("foo", null);
    assertNotNull(foo);
View Full Code Here

    pageContext = new TestPageContext();
    // configure module container
    ServletContext context = pageContext.getServletContext();
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    // configure test module
    module = new TestModuleContext("test", pageContext.getServletContext());
    group.add(module);
    group.setTestModuleContext((HttpServletRequest)pageContext.getRequest(), module);
    // install panels support
    PanelsService service = new PanelsService();
    String xml = "/" + getClass().getName().replace('.', '/') + ".xml";
View Full Code Here

  protected void setUp() throws ServletException {
    request = new TestRequest();
    ServletContext context = request.getSession().getServletContext();
    // configure test module
    module = new TestModuleContext("test", context);
    // configure module container
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    group.add(module);
    // select module
    group.setTestModuleContext(request, module);
View Full Code Here

    request = new TestRequest();
    ServletContext context = request.getSession().getServletContext();
    // set support instance
    context.setAttribute(ModuleSupport.MODULE_SUPPORT_KEY, support = new ModuleSupport());
    // configure test module
    module = new TestModuleContext("test", context);
    // configure module container
    TestModuleGroup group = TestModuleGroup.getInstance(context);
    group.add(module);
    // select module
    group.setTestModuleContext(request, module);
View Full Code Here

TOP

Related Classes of de.odysseus.calyxo.base.test.TestModuleContext

Copyright © 2018 www.massapicom. 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.