make tests pass with Java 7 as well