[IP] Added unit tests.