Make spec work in non-latest environment