Added support for test on Java 8.