add sleeping in tests