Merge "Fix testGetAllNetworkStateSnapshots for non-cellular" into sc-dev

This commit is contained in:
TreeHugger Robot
2021-07-01 10:53:27 +00:00
committed by Android (Google) Code Review

View File

@@ -507,6 +507,7 @@ public class ConnectivityManagerTest {
@Test
public void testGetAllNetworkStateSnapshots()
throws InterruptedException {
assumeTrue(mPackageManager.hasSystemFeature(FEATURE_TELEPHONY));
// Make sure cell is active to retrieve IMSI for verification in later step.
final Network cellNetwork = mCtsNetUtils.connectToCell();
final String subscriberId = getSubscriberIdForCellNetwork(cellNetwork);