Adding DelayedCheck() in testHasWindowFocus.

After executing findViewById(), there are some cases where test case is failed since flags that are set asynchronously are checked only once immediately after that event.

To avoid this, I changed the code to monitor the change of flag.

Change-Id: Iaf30f18144a5ef1887334bc65cbef59ea5de70ac
1 file changed