Add unit tests, and update pom accordingly