Sonar Testing

Sonar Test moved to main loop