Removed debug prints. Refactored test.