Fixed Sonar violation
Fixed NPE while itest