diff --git a/examples/jsf/numberguess/pom.xml b/examples/jsf/numberguess/pom.xml index ed71230a04d..4fe83c6e96e 100644 --- a/examples/jsf/numberguess/pom.xml +++ b/examples/jsf/numberguess/pom.xml @@ -544,10 +544,50 @@ ftest-jboss-remote-60 + + org.codehaus.cargo + cargo-maven2-plugin + + + org.codehaus.mojo + selenium-maven-plugin + + + org.codehaus.mojo + failsafe-maven-plugin + + + org.apache.maven.plugins + maven-antrun-plugin + + + + + + + ftest-jboss-cluster-60 + + + + org.codehaus.mojo + selenium-maven-plugin + + + org.codehaus.mojo + failsafe-maven-plugin + org.apache.maven.plugins - maven-compiler-plugin + maven-antrun-plugin + + + + + + ftest-tomcat-6 + + org.codehaus.cargo cargo-maven2-plugin @@ -567,13 +607,14 @@ + - ftest-jboss-cluster-60 + ftest-jetty-6 - org.apache.maven.plugins - maven-compiler-plugin + org.mortbay.jetty + maven-jetty-plugin org.codehaus.mojo diff --git a/examples/jsf/numberguess/src/ftest/resources/jetty6x.xml b/examples/jsf/numberguess/src/ftest/resources/jetty6x.xml new file mode 100644 index 00000000000..2d4e1806453 --- /dev/null +++ b/examples/jsf/numberguess/src/ftest/resources/jetty6x.xml @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/examples/jsf/numberguess/src/ftest/resources/tomcat6x.xml b/examples/jsf/numberguess/src/ftest/resources/tomcat6x.xml new file mode 100644 index 00000000000..30c3c8d1952 --- /dev/null +++ b/examples/jsf/numberguess/src/ftest/resources/tomcat6x.xml @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/examples/jsf/permalink/pom.xml b/examples/jsf/permalink/pom.xml index 9cfdea5181c..7a0a80739fb 100644 --- a/examples/jsf/permalink/pom.xml +++ b/examples/jsf/permalink/pom.xml @@ -367,10 +367,30 @@ ftest-jboss-remote-60 + + org.codehaus.cargo + cargo-maven2-plugin + + + org.codehaus.mojo + selenium-maven-plugin + + + org.codehaus.mojo + failsafe-maven-plugin + org.apache.maven.plugins - maven-compiler-plugin + maven-antrun-plugin + + + + + + ftest-tomcat-6 + + org.codehaus.cargo cargo-maven2-plugin @@ -391,6 +411,33 @@ + + ftest-jetty-6 + + + + org.mortbay.jetty + maven-jetty-plugin + + src/main/webapp-jetty/WEB-INF/override-web.xml + + + + org.codehaus.mojo + selenium-maven-plugin + + + org.codehaus.mojo + failsafe-maven-plugin + + + org.apache.maven.plugins + maven-antrun-plugin + + + + + restart-embedded diff --git a/examples/jsf/permalink/src/ftest/resources/jetty6x.xml b/examples/jsf/permalink/src/ftest/resources/jetty6x.xml new file mode 100644 index 00000000000..4fccd8c3ac2 --- /dev/null +++ b/examples/jsf/permalink/src/ftest/resources/jetty6x.xml @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/examples/jsf/permalink/src/ftest/resources/tomcat6x.xml b/examples/jsf/permalink/src/ftest/resources/tomcat6x.xml new file mode 100644 index 00000000000..3f6f3ccff23 --- /dev/null +++ b/examples/jsf/permalink/src/ftest/resources/tomcat6x.xml @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/examples/pom.xml b/examples/pom.xml index 9980ee7a7a9..3cb20fc69a4 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -679,6 +679,511 @@ + + + ftest-tomcat-6 + + tomcat6x.xml + + admin + + + + + + org.seleniumhq.selenium.client-drivers + selenium-java-client-driver + test + + + org.jboss.test + richfaces-selenium + ${richfaces.selenium.version} + test + + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + true + + + + + org.codehaus.mojo + build-helper-maven-plugin + + + add-ftest-source + + add-test-source + + + + ${ftest.sources.directory} + + + + + + + + + org.codehaus.cargo + cargo-maven2-plugin + ${cargo.maven2.plugin.version} + + true + + tomcat6x + remote + + + runtime + + http://localhost:8080/manager + ${tomcat.username} + ${tomcat.password} + + + + remote + + + + ${project.build.finalName} + + ${project.groupId} + ${project.artifactId} + war + + + + + + + deploy + pre-integration-test + + deployer-deploy + + + + undeploy + post-integration-test + + deployer-undeploy + + + + + + + + org.codehaus.mojo + selenium-maven-plugin + ${selenium.maven.plugin.version} + + + start-selenium + pre-integration-test + + start-server + + + true + ${selenium.server.port} + true + ${selenium.log.dir}/selenium-server.log + ${selenium.debug} + ${selenium.debug} + + + + + + + + org.codehaus.mojo + failsafe-maven-plugin + + + ${ftest.resources.directory}/${ftest.suite.xml} + + -Xmx748m + once + + + method + ${method} + + + browser + ${selenium.browser} + + + context.root + ${context.root} + + + context.path + ${context.path} + + + selenium.host + ${selenium.server.host} + + + selenium.port + ${selenium.server.port} + + + selenium.debug + ${selenium.debug} + + + selenium.maximize + ${selenium.maximize} + + + maven.resources.dir + ${resources.dir} + + + maven.project.build.directory + ${project.build.directory} + + + selenium.timeout.default + ${selenium.timeout.default} + + + selenium.timeout.gui + ${selenium.timeout.gui} + + + selenium.timeout.ajax + ${selenium.timeout.ajax} + + + selenium.timeout.model + ${selenium.timeout.model} + + + selenium.maximize + ${selenium.maximize} + + + maven.resources.dir + ${resources.dir} + + + maven.project.build.directory + ${project.build.directory} + + + + + + verify + verify + + verify + + + + integration-test + integration-test + + integration-test + + + + + + + + org.apache.maven.plugins + maven-antrun-plugin + + + + stop-selenium + post-integration-test + + + + + + + + run + + + + + + + + + + + ftest-jetty-6 + + jetty6x.xml + 9090 + http://${context.host}:${jetty.http.port}/ + + + + + org.seleniumhq.selenium.client-drivers + selenium-java-client-driver + test + + + org.jboss.test + richfaces-selenium + ${richfaces.selenium.version} + test + + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + true + + + + + org.codehaus.mojo + build-helper-maven-plugin + + + add-ftest-source + + add-test-source + + + + ${ftest.sources.directory} + + + + + + + + + org.mortbay.jetty + maven-jetty-plugin + + + + ${jetty.http.port} + 3600000 + + + 9999 + foo + 10 + ${project.build.directory}/${project.build.finalName} + src/main/webapp-jetty/WEB-INF/web.xml + src/main/webapp-jetty/WEB-INF/jetty-env.xml + + + + start-jetty + pre-integration-test + + run + + + 0 + true + + + + stop-jetty + post-integration-test + + stop + + + + + + + + org.codehaus.mojo + selenium-maven-plugin + ${selenium.maven.plugin.version} + + + start-selenium + pre-integration-test + + start-server + + + true + ${selenium.server.port} + true + ${selenium.log.dir}/selenium-server.log + ${selenium.debug} + ${selenium.debug} + + + + + + + + org.codehaus.mojo + failsafe-maven-plugin + + + ${ftest.resources.directory}/${ftest.suite.xml} + + -Xmx748m + once + + + method + ${method} + + + browser + ${selenium.browser} + + + context.root + ${context.root} + + + context.path + ${context.path} + + + selenium.host + ${selenium.server.host} + + + selenium.port + ${selenium.server.port} + + + selenium.debug + ${selenium.debug} + + + selenium.maximize + ${selenium.maximize} + + + maven.resources.dir + ${resources.dir} + + + maven.project.build.directory + ${project.build.directory} + + + selenium.timeout.default + ${selenium.timeout.default} + + + selenium.timeout.gui + ${selenium.timeout.gui} + + + selenium.timeout.ajax + ${selenium.timeout.ajax} + + + selenium.timeout.model + ${selenium.timeout.model} + + + selenium.maximize + ${selenium.maximize} + + + maven.resources.dir + ${resources.dir} + + + maven.project.build.directory + ${project.build.directory} + + + + + + verify + verify + + verify + + + + integration-test + integration-test + + integration-test + + + + + + + + org.apache.maven.plugins + maven-antrun-plugin + + + + stop-selenium + post-integration-test + + + + + + + + run + + + + + + + + diff --git a/examples/readme.txt b/examples/readme.txt index 5b54d8f9492..136f3172020 100644 --- a/examples/readme.txt +++ b/examples/readme.txt @@ -38,3 +38,20 @@ The jsf/numberguess example can be also tested in a cluster. Follow these steps: 3) run the following command: mvn -Pjboss6cluster,ftest-jboss-cluster-60 clean verify -Djboss.master.configuration=${env.JBOSS_HOME}/server/all + +The jsf/numberguess and jsf/permalink examples can be also tested with Tomcat and Jetty containers. + +Before running the functional tests with Tomcat container, the Tomcat 6 container has to be installed +and running. Before starting Tomcat, add the following line to conf/tomcat-users.xml to allow +the Cargo plugin to access the manager application, then start Tomcat: + + + +The following command will execute functional tests on standalone Tomcat container: + + mvn -Ptomcat,ftest-tomcat-6 clean verify + +An embedded Jetty 6 container is used when running the functional tests with Jetty container. +The following command will execute functional tests with embedded Jetty container: + + mvn -Pjetty,ftest-jetty-6 clean verify