Fix while(true) loop in test, was discarded by javac on Linux