From version 10.2
edited by Eduard Moraru
on 2018/11/26 12:33
To version 11.1
edited by Vincent Massol
on 2018/11/30 00:22
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -xwiki:XWiki.enygma
1 +xwiki:XWiki.VincentMassol
Content
... ... @@ -66,6 +66,7 @@
66 66  |##properties##|No default (empty)|Check the ##*.vm## files for the configuration files to see the list of possible values.|(% style="word-break: break-all;" %)Velocity properties that are applied when generating XWiki's configuration files: ##xwiki.cfg##, ##xwiki.properties## and ##hibernate.cfg.xml##. Example: Tell XWiki that minification is off: ##-Dxwiki.test.ui.properties.xwikiPropertiesAdditionalProperties=debug.minify=false## or ##@UITest(properties = { "xwikiPropertiesAdditionalProperties=debug.minify=false" })##.
67 67  |##extraJARs##|No default (empty)|Comma-separated list of ##<groupId>:<artifactId>##|(% style="word-break: break-all;" %)There are cases where the module being tested cannot be fully deployed as an extension into a running XWiki and it needs to deploy one or several JARs into ##WEB-INF/lib##. One such example is when an extension includes a Hibernate HBM file, as right now only HBM files located in JARs in ##WEB-INF/lib## are supported.
68 68  |##sshPorts##|No default (empty)|List of integers|The list of ports that should be SSH-forwarded when connecting from a Docker container to the host (i.e. when using the ##host.testcontainers.internal##. This is in addition to port ##8080## which is always added. For example if you need XWiki to send a mail to a SMTP server running on port 3025 on the host, you should add port 3025 to the list.
69 +|##profiles##|No default (empty)|Comma-separated list of Maven profile ids|When specified the defined profiles are active when resolving dependencies from the current POM.
69 69  
70 70  = Examples =
71 71  
... ... @@ -148,6 +148,43 @@
148 148  }
149 149  {{/code}}
150 150  
152 += Test Coverage =
153 +
154 +Activate support for Clover by setting the ##xwiki.test.ui.profiles## property in the ##clover## profile in the ##pom.xml## file for the test.
155 +
156 +Example:
157 +
158 +{{code language="java"}}
159 + <profiles>
160 + <profile>
161 + <id>clover</id>
162 + <!-- Add the Clover JAR to the WAR so that it's available at runtime when XWiki executes.
163 + It's needed because instrumented jars in the WAR will call Clover APIs at runtime when they execute. -->
164 + <dependencies>
165 + <dependency>
166 + <groupId>org.openclover</groupId>
167 + <artifactId>clover</artifactId>
168 + </dependency>
169 + </dependencies>
170 + <build>
171 + <plugins>
172 + <plugin>
173 + <groupId>org.apache.maven.plugins</groupId>
174 + <artifactId>maven-failsafe-plugin</artifactId>
175 + <configuration>
176 + <systemProperties combine.children="append">
177 + <!-- Tell the Docker-based test to activate the Clover profile so that the Clover JAR is added to
178 + WEB-INF/lib -->
179 + <property>
180 + <name>xwiki.test.ui.profiles</name>
181 + <value>clover</value>
182 + </property>
183 + </systemProperties>
184 + </configuration>
185 + </plugin>
186 +...
187 +{{/code}}
188 +
151 151  = Architecture =
152 152  
153 153  {{image reference="xwiki-testcontainers.png"/}}

Get Connected