Adding waitForIdleSync in testTouchMode.

There are cases where checking of the status change of main thread is done before setting the focus on UI thread.

In this case, test case fails.

To avoid this, I added waitForIdleSync after UI thread is created to wait for focus setting to be completed.
diff --git a/tests/tests/view/src/android/view/cts/ViewTest.java b/tests/tests/view/src/android/view/cts/ViewTest.java
index 3b9d751..726b0f7 100644
--- a/tests/tests/view/src/android/view/cts/ViewTest.java
+++ b/tests/tests/view/src/android/view/cts/ViewTest.java
@@ -3936,6 +3936,7 @@
                 fitWindowsView.requestFocus();
             }
         });
+        getInstrumentation().waitForIdleSync();
         assertTrue(mockView.isFocusableInTouchMode());
         assertFalse(fitWindowsView.isFocusableInTouchMode());
         assertTrue(mockView.isFocusable());
@@ -3953,12 +3954,14 @@
                 mockView.requestFocus();
             }
         });
+        getInstrumentation().waitForIdleSync();
         assertTrue(mockView.isFocused());
         runTestOnUiThread(new Runnable() {
             public void run() {
                 fitWindowsView.requestFocus();
             }
         });
+        getInstrumentation().waitForIdleSync();
         assertFalse(fitWindowsView.isFocused());
         assertTrue(mockView.isInTouchMode());
         assertTrue(fitWindowsView.isInTouchMode());
@@ -3972,6 +3975,7 @@
                 fitWindowsView.requestFocus();
             }
         });
+        getInstrumentation().waitForIdleSync();
         assertFalse(mockView.isFocused());
         assertTrue(fitWindowsView.isFocused());
         assertFalse(mockView.isInTouchMode());