I have a AppEngine application that exposes some APIs. Right now I'm writing tests for those APIs but some of them enqueue tasks. I'm not sure how I can write a test case that waits for all the tasks that certain API call enqueued to finish.
Any ideas how within a test itself I can verify that certain tasks have finished?