fix race condition in spec.