Merge "Add sleep to avoid calling stopLocalOnlyHotspot before TetherController initialization." into pie-cts-dev

am: 4d452396c9

Change-Id: I8e53f1b42ad21330e607827e1b6eedbb0837696d
This commit is contained in:
jungyee.yoo
2019-02-27 15:37:20 -08:00
committed by android-build-merger

View File

@@ -874,6 +874,15 @@ public class WifiManagerTest extends AndroidTestCase {
TestLocalOnlyHotspotCallback callback = startLocalOnlyHotspot();
// add sleep to avoid calling stopLocalOnlyHotspot before TetherController initialization.
// TODO: remove this sleep as soon as b/124330089 is fixed.
try {
Log.d(TAG, "Sleep for 2 seconds");
Thread.sleep(2000);
} catch (InterruptedException e) {
Log.d(TAG, "Thread InterruptedException!");
}
stopLocalOnlyHotspot(callback, wifiEnabled);
// wifi should either stay on, or come back on
@@ -949,6 +958,15 @@ public class WifiManagerTest extends AndroidTestCase {
}
assertTrue(caughtException);
// add sleep to avoid calling stopLocalOnlyHotspot before TetherController initialization.
// TODO: remove this sleep as soon as b/124330089 is fixed.
try {
Log.d(TAG, "Sleep for 2 seconds");
Thread.sleep(2000);
} catch (InterruptedException e) {
Log.d(TAG, "Thread InterruptedException!");
}
stopLocalOnlyHotspot(callback, wifiEnabled);
}
}