Additional refactoring of NGTests and added Javadoc