#3215 - fixing race in JavaTestkitSpec