Good idea. Unfortunately, the current NSURLConnection implementation has issues with executing delegate callbacks on background threads. As the unit tests execute only in the UI thread, the act of test waiting for completion blocks the UI thread and the callbacks are never executed. I am working on resolving the issue, potentially through leveraging NSURLSession class. The problem is tracked by internal bug #123930