Add javadoc, fix test file content