Merge "New unit tests and sonar fixes"