Whenever you visit Traffic department or police station for any transaction, even getting police report for traffic accident, they will check first the violation and tell you to clear it before they proceed with any transaction. So don't worry, once you will transfer the car in your name, they will check it for violation.