testing waiting in python