Worblehat

Build Status

Worblehat is a training application for the Scrum for Developers training held by codecentric AG.

Requirements

  • JDK 11+
  • Docker

Maven comes bundled with the maven wrapper scripts, no need for manual installation before.

Running the application

  1. Compile and install the application in the local maven repository with ./mvnw install
  2. Start the database. The easiest way is to fire up a docker container with worblehat-web/docker-db.sh.
  3. Run the application.:
  • Either run ./mvnw -pl worblehat-web spring-boot:run (will automatically compile & package the application before)
  • Or use your IDE to start the main class in worblehat-web: de.codecentric.psd.Worblehat
  1. Access the application at http://localhost:8080/worblehat/

Running tests

All tests are executed via JUnit, but can be conceptually divided in unit and integration tests. They are bound to different maven lifecycle phases, are executed by differen maven plugins, and follow a different naming scheme.

Unit Tests

  1. Unit tests are run with ./mvnw test
  2. The maven-surefire-plugin includes all these tests by default:
<includes>
   <include>**/Test*.java</include>
   <include>**/*Test.java</include>
   <include>**/*Tests.java</include>
   <include>**/*TestCase.java</include>
</includes>

Acceptance Tests

  1. Acceptance tests are run by activating the required profile ./mvnw -P runITs verify.

    Note: The verify lifecycle is executed before install. Integration tests are only included, if the runITs profile is activated.

  2. The maven-failsafe-plugin includes all these tests by default:

<includes>
   <include>**/IT*.java</include>
   <include>**/*IT.java</include>
   <include>**/*ITCase.java</include>
</includes>

The acceptance tests spin docker containers for all required dependencies (Database & Browser) via Testcontainers.

Howto Release

To release for example version 1.2 follow these steps:

  1. Set next development version: mvn versions:set -DnewVersion=1.2.0 -DgenerateBackupPoms=false
  2. Create a tag and push the tag back to the team repository
  3. Let jenkins build the release and deploy it to the test and production environments
  4. Bump the version for the next development iteration: mvn versions:set -DnewVersion=1.3.0-SNAPSHOT -DgenerateBackupPoms=false