This is just a design study. It is not pseudo code but the intent is the same: I just wanted to study the design of the creation of a user that receives in input also some roles that needs to be checked the existence for.
To build and run the all the tests use:
$ mvn verify
While to launch only the unit tests:
$ mvn clean install -Punit-tests-only
While to launch only the integration tests:
$ mvn clean install -Pintegration-tests-only
To run the application, you need to build it using maven and then to launch the command:
$ java -jar emapp.jar