Fixed test failure that was happening in JDK7