Unit tested some functions.
Ongoing work on jdk8