SONAR-4412 Updated expected exceptions in unit tests