Write Test Case For Settimeout In Python