Fixed test that was failing on JDK 1.7