Added some JUnit tests