Added some more JUnit tests.