From 33cfd945a37f884cb5bc568d7e1c3f5a68d8e592 Mon Sep 17 00:00:00 2001 From: jensp Date: Thu, 1 Oct 2015 12:10:48 +0000 Subject: [PATCH] CCM NG: Improved documentation for setting up the test environement git-svn-id: https://svn.libreccm.org/ccm/ccm_ng@3665 8810af33-2d31-482b-a856-94f89814c4df --- src/site/apt/testing.apt | 63 +++++++++++++++++++++++++++++++++------- 1 file changed, 52 insertions(+), 11 deletions(-) diff --git a/src/site/apt/testing.apt b/src/site/apt/testing.apt index 461cef837..3cb118b73 100644 --- a/src/site/apt/testing.apt +++ b/src/site/apt/testing.apt @@ -33,8 +33,8 @@ Testing LibreCCM -------------------------------------------------------------------------------- are only executed when special Maven profiles are used. These profiles are - used to control against which Application server Arquillan should run its - tests. + used to control which Application server Arquillan should use to run the + integration tests. * Available profiles @@ -62,7 +62,7 @@ Testing LibreCCM * Structure of the profiles For each profile their is separate resource directory in the - <<>> directory of the module which at least + <<>> directory of the module which at least contains these files: [arquillian.xml] Configuration file for Arquillian. @@ -73,20 +73,61 @@ Testing LibreCCM is that the <<>> configures Hibernate to automatically drop the database and recreate the schema. The production <<>> is configured to only verify the schema. Schema - creation and migrations are done by LibreCCM. + creation and migrations are done by LibreCCM using the Flyway framework. * Preparing the remote Application Servers -** Wildfly 8 +** Wildfly 8.2.x - For using the remote profiles you have to install a Wildfly application - server on the system you want to run the tests on an configure these - datasources: + For using the remote profiles you have to install a + {{{http://wildfly.org/}Wildfly application server}} + on the system you want to run the tests on. At them moment we recommend to + use version 8.2.1. The installation is + described in the {{{https://docs.jboss.org/author/display/WFLY8/Getting+Started+Guide}Wildfly documentation}}. - [java:/comp/env/jdbc/org/libreccm/ccm-core/h2-mem] A in memory database - using the H2 database which is part of Wildfly. + If you want to use the <<>> profile you have to + create a new datasource in Wildfly. The easiest way to do that is the use + Admin UI of Wildfly. Open the Admin UI in your browser, go the + <<>>, <<>>, <<>> and create a new + datasource with these properties: + + [JNDI name] <<>> - [java:/comp/env/jdbc/org/libreccm/ccm-core/pgsql] PostgresSQL database + [Name] <<>> + + [Connection URL] <<>> + + [Username] <<>> + + [Password] can be empty + + This uses the the H2 database engine which bundled with Wildfly. The + database is an in memory database which exists only in the RAM. + + If you want to use the <<>> some more steps are + necessary. First you need a working PostgreSQL installation. We recommend + version 9.4. Create a new database user <<>> with a password and a new + database <<>> which is owned by the user you just created. + + Download the {{{https://jdbc.postgresql.org/}JDBC driver for PostgreSQL}}. + Open the Admin UI of your Wildfly installation and and to <<>>. + Click the <<> button and select the file of the PostgreSQL JDBC driver. + Click next and check the <<>> checkbox of the next page, then click + <<>>. You should now see the deployed driver in the list of + deployments. + + Then go to <<>>, <<>>, <<>> and create a new + datasource with these properties: + + [JNDI name] <<>> + + [Name] <<>> + + [Connection URL] <<>> + + [Username] <<>> + + [Password] <<>> Please note that the database is recreated after each test. Therefore you should not use a production database. \ No newline at end of file