Added tutorials of the hibernate-release 5.0.12.Final
[hibernate4-maven-plugin] / src / it / hmp-testclasses-annotationscanning / readme.txt
1 Example-Project "Hibernate-Maven-Plugin Testclasses Annotation-Scanning"\r
2 \r
3 This is a small Exampleproject for a base Database-Integrationtest, with the use of the "Hibernate Maven Plugin" from de.juplo for the automatic Generation and the Execution of the create-schema-sql-script. \r
4 \r
5 The hibernate-maven-plugin - defined in the plugins-section in the pom.xml -  scans the code for Entities to create the schema-script. Entity-Scanning is or can be done in following 3 locations:\r
6 *) Project-Classes: By default, the plugin scans for @Entitiy-Annotated classes under "target/classes".\r
7 *) Project-Testclasses: By default, the plugin scans for @Entitiy-Annotated classes under "target/test-classes".\r
8 *) Project-Dependencies: Compile-Time-Dependencies wil also be scanned.\r
9 \r
10 Test-Structure:\r
11 -) Basic Code for User-Change-Tracking over JPA EntityListener: Some basic Interfaces and Classes for a automatic tracking of the User and the Date at the Phases PRE-PERSIST and PRE-UPDATE are located under src/main/java.\r
12 -) The important Test-Entity "UserChangeInfoTest" for testing the userinfo-tracking and the Testservice-Declaration and -Implementation for storing/updating/reading such Test-Entity is located under src/test/java. \r
13 -) Integrationtest(s): The Integrationtest "UserChangeInfoTest" is based on Arquillian. Arquillian starts an OpenEJB Embedded Container, seeds the Database with Testdata, and executes the Integrationtest.\r
14 -) Dataset-Files, and different configurationfiles for Arquillian, JPA, Logback,... are located under src/test/resources.\r
15 \r
16 \r
17 Building the Project:\r
18 As usual: To build and install the project into your local maven-repository, execute "mvn install".\r
19 \r