Added some refactorings and unit tests
Added some refactorings and unit tests
Latest updates