You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2016/12/30 14:47:47 UTC
[4/4] syncope git commit: More handful enduser test handling for devs
+ updated build instructions
More handful enduser test handling for devs + updated build instructions
Project: http://git-wip-us.apache.org/repos/asf/syncope/repo
Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/f1b0c996
Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/f1b0c996
Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/f1b0c996
Branch: refs/heads/2_0_X
Commit: f1b0c996910da84d33ae8426640a832974675063
Parents: 0b0734c
Author: Francesco Chicchiricc� <il...@apache.org>
Authored: Fri Dec 30 15:46:39 2016 +0100
Committer: Francesco Chicchiricc� <il...@apache.org>
Committed: Fri Dec 30 15:47:35 2016 +0100
----------------------------------------------------------------------
fit/console-reference/pom.xml | 65 ++++++++++-----------
fit/core-reference/pom.xml | 101 +++++++++++++++-----------------
fit/enduser-reference/pom.xml | 114 +++++++++++++++++--------------------
src/site/xdoc/building.xml | 52 ++++++++++-------
4 files changed, 161 insertions(+), 171 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/syncope/blob/f1b0c996/fit/console-reference/pom.xml
----------------------------------------------------------------------
diff --git a/fit/console-reference/pom.xml b/fit/console-reference/pom.xml
index 6b5b335..0c43a50 100644
--- a/fit/console-reference/pom.xml
+++ b/fit/console-reference/pom.xml
@@ -259,31 +259,30 @@ under the License.
<profiles>
<profile>
- <id>debug</id>
-
- <properties>
- <skipTests>true</skipTests>
- </properties>
-
+ <id>skipTests</id>
+
<build>
- <defaultGoal>clean verify cargo:run</defaultGoal>
-
<plugins>
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<inherited>true</inherited>
<configuration>
- <configuration>
- <properties>
- <cargo.jvmargs>-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n
- -Dwicket.configuration=development
- -XX:+CMSClassUnloadingEnabled -XX:+UseConcMarkSweepGC -XX:MaxPermSize=512m -Xmx1024m -Xms512m</cargo.jvmargs>
- </properties>
- </configuration>
+ <deployables>
+ <deployable>
+ <location>${project.build.directory}/${project.build.finalName}.war</location>
+ </deployable>
+ </deployables>
</configuration>
<executions>
<execution>
+ <id>install-container</id>
+ <phase>package</phase>
+ <goals>
+ <goal>install</goal>
+ </goals>
+ </execution>
+ <execution>
<id>start-container</id>
<phase>none</phase>
</execution>
@@ -296,39 +295,33 @@ under the License.
</plugins>
</build>
</profile>
-
+
<profile>
- <id>skipTests</id>
+ <id>debug</id>
+
+ <properties>
+ <skipTests>true</skipTests>
+ </properties>
- <dependencies>
- <dependency>
- <groupId>com.h2database</groupId>
- <artifactId>h2</artifactId>
- </dependency>
- </dependencies>
-
<build>
+ <defaultGoal>clean verify cargo:run</defaultGoal>
+
<plugins>
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<inherited>true</inherited>
<configuration>
- <deployables>
- <deployable>
- <location>${project.build.directory}/${project.build.finalName}.war</location>
- </deployable>
- </deployables>
+ <configuration>
+ <properties>
+ <cargo.jvmargs>-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n
+ -Dwicket.configuration=development
+ -XX:+CMSClassUnloadingEnabled -XX:+UseConcMarkSweepGC -XX:MaxPermSize=512m -Xmx1024m -Xms512m</cargo.jvmargs>
+ </properties>
+ </configuration>
</configuration>
<executions>
<execution>
- <id>install-container</id>
- <phase>package</phase>
- <goals>
- <goal>install</goal>
- </goals>
- </execution>
- <execution>
<id>start-container</id>
<phase>none</phase>
</execution>
http://git-wip-us.apache.org/repos/asf/syncope/blob/f1b0c996/fit/core-reference/pom.xml
----------------------------------------------------------------------
diff --git a/fit/core-reference/pom.xml b/fit/core-reference/pom.xml
index 9b2445e..c7f9da9 100644
--- a/fit/core-reference/pom.xml
+++ b/fit/core-reference/pom.xml
@@ -803,6 +803,53 @@ under the License.
</profile>
<profile>
+ <id>skipTests</id>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <inherited>true</inherited>
+ <configuration>
+ <skipTests>${skipTests}</skipTests>
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <groupId>org.codehaus.cargo</groupId>
+ <artifactId>cargo-maven2-plugin</artifactId>
+ <inherited>true</inherited>
+ <configuration>
+ <deployables>
+ <deployable>
+ <location>${project.build.directory}/${project.build.finalName}.war</location>
+ </deployable>
+ </deployables>
+ </configuration>
+ <executions>
+ <execution>
+ <id>install-container</id>
+ <phase>package</phase>
+ <goals>
+ <goal>install</goal>
+ </goals>
+ </execution>
+ <execution>
+ <id>start-container</id>
+ <phase>none</phase>
+ </execution>
+ <execution>
+ <id>stop-container</id>
+ <phase>none</phase>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+
+ <profile>
<id>debug</id>
<properties>
@@ -889,60 +936,6 @@ under the License.
</resources>
</build>
</profile>
-
- <profile>
- <id>skipTests</id>
-
- <dependencies>
- <dependency>
- <groupId>com.h2database</groupId>
- <artifactId>h2</artifactId>
- </dependency>
- </dependencies>
-
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-failsafe-plugin</artifactId>
- <inherited>true</inherited>
- <configuration>
- <skipTests>${skipTests}</skipTests>
- </configuration>
- </plugin>
-
- <plugin>
- <groupId>org.codehaus.cargo</groupId>
- <artifactId>cargo-maven2-plugin</artifactId>
- <inherited>true</inherited>
- <configuration>
- <deployables>
- <deployable>
- <location>${project.build.directory}/${project.build.finalName}.war</location>
- </deployable>
- </deployables>
- </configuration>
- <executions>
- <execution>
- <id>install-container</id>
- <phase>package</phase>
- <goals>
- <goal>install</goal>
- </goals>
- </execution>
- <execution>
- <id>start-container</id>
- <phase>none</phase>
- </execution>
- <execution>
- <id>stop-container</id>
- <phase>none</phase>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- </profile>
<profile>
<id>all</id>
http://git-wip-us.apache.org/repos/asf/syncope/blob/f1b0c996/fit/enduser-reference/pom.xml
----------------------------------------------------------------------
diff --git a/fit/enduser-reference/pom.xml b/fit/enduser-reference/pom.xml
index d490d12..d061281 100644
--- a/fit/enduser-reference/pom.xml
+++ b/fit/enduser-reference/pom.xml
@@ -388,40 +388,46 @@ under the License.
<id>windows-it</id>
<activation>
- <os><family>Windows</family></os>
+ <os>
+ <family>Windows</family>
+ </os>
</activation>
<properties>
- <protractor.cmd>${enduser-test.dir}/nodejs/node/node_modules/protractor/bin/protractor</protractor.cmd>
- <webdriver-manager.cmd>${enduser-test.dir}/nodejs/node/node_modules/protractor/bin/webdriver-manager</webdriver-manager.cmd>
+ <protractor.cmd>${enduser-test.dir}/nodejs/node/node_modules/protractor/bin/protractor</protractor.cmd>
+ <webdriver-manager.cmd>${enduser-test.dir}/nodejs/node/node_modules/protractor/bin/webdriver-manager</webdriver-manager.cmd>
</properties>
</profile>
<profile>
- <id>debug</id>
+ <id>skipTests</id>
<properties>
<skipTests>true</skipTests>
</properties>
-
+
<build>
- <defaultGoal>clean verify cargo:run</defaultGoal>
-
- <plugins>
+ <plugins>
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<inherited>true</inherited>
<configuration>
- <configuration>
- <properties>
- <cargo.jvmargs>-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n
- -XX:+CMSClassUnloadingEnabled -XX:+UseConcMarkSweepGC -XX:MaxPermSize=512m</cargo.jvmargs>
- </properties>
- </configuration>
+ <deployables>
+ <deployable>
+ <location>${project.build.directory}/${project.build.finalName}.war</location>
+ </deployable>
+ </deployables>
</configuration>
<executions>
<execution>
+ <id>install-container</id>
+ <phase>package</phase>
+ <goals>
+ <goal>install</goal>
+ </goals>
+ </execution>
+ <execution>
<id>start-container</id>
<phase>none</phase>
</execution>
@@ -431,57 +437,43 @@ under the License.
</execution>
</executions>
</plugin>
-
+ </plugins>
+ </build>
+ </profile>
+
+ <profile>
+ <id>debug</id>
+
+ <build>
+ <defaultGoal>clean verify cargo:run</defaultGoal>
+
+ <plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
+ <inherited>true</inherited>
<executions>
<execution>
- <id>Execute Tests</id>
+ <id>exec-protractor</id>
<phase>none</phase>
- </execution>
+ </execution>
</executions>
</plugin>
- </plugins>
- </build>
- </profile>
-
- <profile>
- <id>skipTests</id>
-
- <properties>
- <skipTests>true</skipTests>
- </properties>
-
- <dependencies>
- <dependency>
- <groupId>com.h2database</groupId>
- <artifactId>h2</artifactId>
- </dependency>
- </dependencies>
- <build>
- <plugins>
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<inherited>true</inherited>
<configuration>
- <deployables>
- <deployable>
- <location>${project.build.directory}/${project.build.finalName}.war</location>
- </deployable>
- </deployables>
+ <configuration>
+ <properties>
+ <cargo.jvmargs>-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n
+ -XX:+CMSClassUnloadingEnabled -XX:+UseConcMarkSweepGC -XX:MaxPermSize=512m</cargo.jvmargs>
+ </properties>
+ </configuration>
</configuration>
<executions>
<execution>
- <id>install-container</id>
- <phase>package</phase>
- <goals>
- <goal>install</goal>
- </goals>
- </execution>
- <execution>
<id>start-container</id>
<phase>none</phase>
</execution>
@@ -500,13 +492,24 @@ under the License.
<properties>
<tomcat.version>8.0.39</tomcat.version>
- <skipTests>true</skipTests>
</properties>
<build>
<defaultGoal>clean verify cargo:run</defaultGoal>
- <plugins>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>exec-maven-plugin</artifactId>
+ <inherited>true</inherited>
+ <executions>
+ <execution>
+ <id>exec-protractor</id>
+ <phase>none</phase>
+ </execution>
+ </executions>
+ </plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
@@ -552,17 +555,6 @@ under the License.
</execution>
</executions>
</plugin>
-
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>exec-maven-plugin</artifactId>
- <executions>
- <execution>
- <id>Execute Tests</id>
- <phase>none</phase>
- </execution>
- </executions>
- </plugin>
</plugins>
<resources>
http://git-wip-us.apache.org/repos/asf/syncope/blob/f1b0c996/src/site/xdoc/building.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/building.xml b/src/site/xdoc/building.xml
index 034169f..32718e7 100644
--- a/src/site/xdoc/building.xml
+++ b/src/site/xdoc/building.xml
@@ -47,28 +47,34 @@ under the License.
<section name="Building Syncope">
<p>
- Before building Syncope, you need to setup an environment variable to give Maven more memory.<br/>
+ Before building Syncope, you need to setup an environment variable to give Maven more memory.
+ </p>
+ <p>
On Unix
<source>export MAVEN_OPTS="-Xms512m -Xmx1024m -XX:PermSize=256m -XX:MaxPermSize=512m"</source>
+ </p>
+ <p>
On Windows
<source>set MAVEN_OPTS=-Xms512m -Xmx1024m -XX:PermSize=256m -XX:MaxPermSize=512m</source>
</p>
<p>
- To build Syncope simply execute (from within the check-out directory):
- <source>$ mvn install</source>
- or
+ To build Syncope simply execute (from within the top-level source directory):
<source>$ mvn clean install</source>
- for subsequent runs.<br/>
- To build Syncope without running any test do:
- <source>$ mvn -PskipTests</source>
- <b>Important</b>: For subsequent builds (e.g., after code changes are made),
- run <code>mvn clean</code> first to build from scratch, before using one of the <code>mvn install</code>
- commands above.
- (You may also wish to run <code>git pull</code> after running <code>mvn clean</code> but before running
- <code>mvn install</code>.)
+ </p>
+ <p>
+ To build Syncope without running any test nor check do:
+ <source>$ mvn -PskipTests,all</source>
</p>
</section>
+ <section name="Building documentation">
+ <p>
+ To build Syncope documentation execute (from within the top-level source directory):
+ <source>$ mvn -N -P site clean generate-resources</source>
+ The documentation artifacts are now be available under <tt>target/generated-docs/</tt>.
+ </p>
+ </section>
+
<section name="More build profiles">
<p>
Besides default, other Maven
@@ -91,6 +97,13 @@ under the License.
or, without Activiti and Camel support
<source>$ mvn -Pdebug</source>
+ <p>
+ Once started in debug mode, individual test methods can be executed as follows (the
+ <a href="https://maven.apache.org/surefire/maven-surefire-plugin/examples/single-test.html">
+ Maven Surefire Plugins rules</a> apply here):
+ <source>$ mvn test -Dtest=UserITCase#list</source>
+ </p>
+
<h4>JRebel</h4>
As with Debug, but with <a href="http://zeroturnaround.com/software/jrebel/">JRebel</a> features enabled.
<source>$ export REBEL_HOME=/opt/jrebel
@@ -168,6 +181,13 @@ $ mvn -Pjrebel</source>
enduser) and enables remote JPDA debugging on port 8000 in the running Java EE container (Tomcat).
<source>$ mvn -Pdebug</source>
+ <p>
+ Once started in debug mode, the test cases can be executed as follows:
+ <source>$ cd target/enduser-test
+$ nodejs/node/node nodejs/bin/protractor protractor-conf.js</source>
+ where the actual tests to be run can be selected by modifying the <code>protractor-conf.js</code> content.
+ </p>
+
<h4>JRebel</h4>
As with Debug, but with <a href="http://zeroturnaround.com/software/jrebel/">JRebel</a> features enabled.
<source>$ export REBEL_HOME=/opt/jrebel
@@ -182,13 +202,5 @@ $ mvn -Pjrebel</source>
<source>$ mvn -Peclipse-it</source>
</subsection>
</section>
-
- <section name="Building documentation">
- <p>
- To build Syncope documentation execute (from within the check-out directory):
- <source>$ mvn -N -P site clean generate-resources</source>
- The documentation artifacts are now be available under <tt>target/generated-docs/</tt>.
- </p>
- </section>
</body>
</document>