fixed integration tests
and changed register controller method to post
some refactorings,
added missing properties,
fixed missing user id in registration,
checked some preconditions
added tests for branch coverage