/
Testing of the JBoss/Wildfly deployment
Testing of the JBoss/Wildfly deployment
The purpose of this page is explain how to test the TASKANA web application on a Wildfly Application server.
Integration Tests
There are dedicated integration tests for the TASKANA application on Wildfly. They can be found here: https://github.com/Taskana/taskana/tree/master/rest/taskana-rest-spring-example-wildfly/src/test/java/pro/taskana
These tests are based on a Wildfly server managed by Arquillian.
The default runs an integration test with a H2 datasource. You can change this to PostgreSQL by providing an environment variable to the test:
-Ddb-type=postgres
This will use the application-<db-type>.properties instead.
Maven Build
The Maven build will download the Wildfly server and unpack it into the target directory:
<execution> <id>unpack-wildfly</id> <phase>process-test-classes</phase> <goals> <goal>unpack</goal> </goals> <configuration> <artifactItems> <artifactItem> <groupId>org.wildfly</groupId> <artifactId>wildfly-dist</artifactId> <version>${version.wildfly}</version> <type>zip</type> <overWrite>false</overWrite> <outputDirectory>${project.build.directory}</outputDirectory> </artifactItem> </artifactItems> </configuration> </execution>
Furthermore the PostgreSQL database driver will be registered:
<execution> <id>copy-postgres-db-driver</id> <phase>process-test-classes</phase> <goals> <goal>copy</goal> </goals> <configuration> <artifactItems> <artifactItem> <groupId>org.postgresql</groupId> <artifactId>postgresql</artifactId> <outputDirectory>${project.build.directory}/wildfly-${version.wildfly}/modules/system/layers/base/org/postgresql/main</outputDirectory> </artifactItem> </artifactItems> </configuration> </execution> [...] <execution> <id>copy-module-xml</id> <phase>process-test-classes</phase> <goals> <goal>copy-resources</goal> </goals> <configuration> <outputDirectory>${project.build.directory}/wildfly-${version.wildfly}/modules/system/layers/base/org/postgresql/main</outputDirectory> <resources> <resource> <directory>src/test/resources</directory> <includes> <include>module.xml</include> </includes> </resource> </resources> </configuration> </execution>
, multiple selections available,
Related content
TODO - Wildfly Application Server configuration
TODO - Wildfly Application Server configuration
Read with this
Test User Structure
Test User Structure
Read with this
Failed task creation handling / configuration / monitoring
Failed task creation handling / configuration / monitoring
More like this
Adapter Properties
Adapter Properties
More like this