Added test project and 2 unit tests
Small code refactoring (renaming, reordering)