Add unit test

TODO: Add unit tests for all other cases
Update pom