Skip to content

chr-krenn/chr-krenn-fhj-ws2017-sd17-pse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chr-krenn-fhj-ws2017-sd17-pse

Students SW-Project

Links

Setup & run


Please read the contributing rules: https://github.com/chr-krenn/chr-krenn-fhj-ws2017-sd17-pse/blob/master/CONTRIBUTING.md

Clone Repository
cd ~/eclipse-workspace
git clone https://github.com/chr-krenn/chr-krenn-fhj-ws2017-sd17-pse
Copy the content of
~/eclipse-workspace/chr-krenn-fhj-ws2017-sd17-pse/doc/data/SETUP_WILDFLY/
into
~/install/wildfly-10.1.0.Final/
Enable and start database service:
systemctl enable mariadb.service
systemctl start mariadb.service
Use MySQL shell to set up the database, grant privileges, and insert sample data:
cd ~/eclipse-workspace/chr-krenn-fhj-ws2017-sd17-pse/
mysql -u root -p
Copy/paste the following commands to __create the database__:
source sql/init.sql;
exit
Start the Wildfly server with the __standalone.sh__ (use doc/data/SETUP_WILDFLY/standalone/configuration/standalone.xml configuration to use the MySQL datasource).
~/install/wildfly-10.1.0.Final/bin/standalone.sh

After that run the unit/integration tests or deploy the app:

# deploy the app without any testing as fast as possible
# (sample data will still be inserted!)
mvn clean wildfly:deploy -DskipTests -Djacoco.skip=true

# run unit tests and package application:
mvn clean package

# run unit tests and deploy application:
mvn clean wildfly:deploy

# run unit/integration tests with coverage analysis, deploy application, run UI tests:
mvn clean wildfly:deploy verify

# run unit tests:
mvn test

# run unit tests, DAO tests, and UI tests:
mvn clean verify

To access the application open: http://localhost:8080/pse/index.xhtml

Code coverage analysis

Code coverage reports for unit and integration tests are generated at

  • target/site/jacoco-ut/index.html
  • target/site/jacoco-it/index.html

Static code analysis

Run mvn pmd:pmd for pmd report Run mvn pmd:cpd for cpd report Run mvn jdepend:generate for jdepend report Run mvn test site for findbugs report(compile source before)

All reports will be shown in target/site directory

Important

Don't use scripts which are archived into the doc directory. Those are only archived for the possibility to reuse them if needed.

The JUnit test would fail if the tables contain any data. To clean the tables use the truncate.sql script in the sql directory.

source sql/truncate.sql;

If something went wrong drop the database and make a new clean setup of the database.

drop database pse;

If you clean your local git repository don't forget to delete the deployment section in the standalone.xml of Wildfly. For this purpose search for the standalone.xml in the ~/install/wildfly-10.1.0.Final/standalone/configuration/ directory. Go to the end of the file and delete the <deployments>...</deployments> tag.

UI Testing

Setup Selenium IDE

UI Test Class Diagram

UI Test Class Diagram

Optional

Set up management user to access WildFly management console at http://localhost:9990:

~/install/wildfly-10.1.0.Final/bin/add-user.sh

Database Design

This database diagram is automatically generated by doc/generate_database_doc.sh. Rerun this script after making any changes to the database schema. Detailed database documentation can be viewed at doc/db_schema/index.html. Database Schema

About

Students SW-Project

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published