Written tests for User handling. Added improved support for merging and updating user data for user object