Merge "Revert isDefaultNetworkActive behavior when there is no default network" into main

This commit is contained in:
Motomu Utsumi
2023-08-01 05:49:47 +00:00
committed by Gerrit Code Review
2 changed files with 9 additions and 5 deletions

View File

@@ -11330,7 +11330,8 @@ public class ConnectivityServiceTest {
@Test
public void testIsDefaultNetworkActiveNoDefaultNetwork() throws Exception {
assertFalse(mCm.isDefaultNetworkActive());
// isDefaultNetworkActive returns true if there is no default network, which is known issue.
assertTrue(mCm.isDefaultNetworkActive());
final LinkProperties cellLp = new LinkProperties();
cellLp.setInterfaceName(MOBILE_IFNAME);
@@ -11342,7 +11343,7 @@ public class ConnectivityServiceTest {
mCellAgent.disconnect();
waitForIdle();
assertFalse(mCm.isDefaultNetworkActive());
assertTrue(mCm.isDefaultNetworkActive());
}
@Test