Added test to calculate manharan distance, refactored the factory class