public FacesEnvironment withSeam() { checkNotInitialized(); try { Filter ajaxFilter = createInstance("org.jboss.seam.servlet.SeamFilter"); withFilter("ajax4jsf", ajaxFilter); EventListener seamListener = createInstance("org.jboss.seam.servlet.SeamListener"); facesServer.addWebListener(seamListener); webXmlDefault = "org/jboss/test/faces/ajax-web.xml"; return this; } catch (ClassNotFoundException e) { throw new TestException(e); } }
public FacesEnvironment withSeam() { checkNotInitialized(); try { Filter ajaxFilter = createInstance("org.jboss.seam.servlet.SeamFilter"); withFilter("ajax4jsf", ajaxFilter); EventListener seamListener = createInstance("org.jboss.seam.servlet.SeamListener"); facesServer.addWebListener(seamListener); webXmlDefault = "org/jboss/test/faces/ajax-web.xml"; return this; } catch (ClassNotFoundException e) { throw new TestException(e); } }
/** * This hook method called from the {@link #setUp()} should append JSF implementation listener to the test server. * Default version applends "com.sun.faces.config.ConfigureListener" or * "org.apache.myfaces.webapp.StartupServletContextListener" for the existed SUN RI or MyFaces implementation. This * metod also calls appropriate {@link #setupSunFaces()} or {@link #setupMyFaces()} methods. */ protected void setupFacesListener() { EventListener listener = null; try { // Check Sun RI configuration listener class. listener = createInstance("com.sun.faces.config.ConfigureListener"); setupSunFaces(); } catch (ClassNotFoundException e) { // No JSF RI listener, check MyFaces. try { listener = createInstance("org.apache.myfaces.webapp.StartupServletContextListener"); setupMyFaces(); } catch (ClassNotFoundException e1) { throw new TestException("No JSF listeners have been found", e1); } } facesServer.addWebListener(listener); }
/** * This hook method called from the {@link #setUp()} should append JSF implementation listener to the test server. * Default version applends "com.sun.faces.config.ConfigureListener" or * "org.apache.myfaces.webapp.StartupServletContextListener" for the existed SUN RI or MyFaces implementation. This * metod also calls appropriate {@link #setupSunFaces()} or {@link #setupMyFaces()} methods. */ protected void setupFacesListener() { EventListener listener = null; try { // Check Sun RI configuration listener class. listener = createInstance("com.sun.faces.config.ConfigureListener"); setupSunFaces(); } catch (ClassNotFoundException e) { // No JSF RI listener, check MyFaces. try { listener = createInstance("org.apache.myfaces.webapp.StartupServletContextListener"); setupMyFaces(); } catch (ClassNotFoundException e1) { throw new TestException("No JSF listeners have been found", e1); } } facesServer.addWebListener(listener); }
public FacesEnvironment withRichFaces() { checkNotInitialized(); try { Filter ajaxFilter = createInstance("org.ajax4jsf.Filter"); withFilter("ajax4jsf", ajaxFilter); webXmlDefault = "org/jboss/test/faces/ajax-web.xml"; return this; } catch (ClassNotFoundException e) { throw new TestException(e); } }
public FacesEnvironment withRichFaces() { checkNotInitialized(); try { Filter ajaxFilter = createInstance("org.ajax4jsf.Filter"); withFilter("ajax4jsf", ajaxFilter); webXmlDefault = "org/jboss/test/faces/ajax-web.xml"; return this; } catch (ClassNotFoundException e) { throw new TestException(e); } }