Given a function handling requests on a connection the body of the function is a infinite loop:
def handle_connection():
# initialize stuff
...
while True:
# stuff to get the request
...
# stuff to handle the request
...
How would I unittest this function?
Aucun commentaire:
Enregistrer un commentaire