start refactoring and testing
put bases of TDD and require modules