Merge "Avoid hardcoding BATTERY_PLUGGED_ANY constant."
This commit is contained in:
commit
bdd3ca1ac6
1 changed files with 1 additions and 7 deletions
|
|
@ -18,9 +18,7 @@ package com.android.cts.net.hostside;
|
|||
|
||||
import static android.app.job.JobScheduler.RESULT_SUCCESS;
|
||||
import static android.net.ConnectivityManager.ACTION_RESTRICT_BACKGROUND_CHANGED;
|
||||
import static android.os.BatteryManager.BATTERY_PLUGGED_AC;
|
||||
import static android.os.BatteryManager.BATTERY_PLUGGED_USB;
|
||||
import static android.os.BatteryManager.BATTERY_PLUGGED_WIRELESS;
|
||||
import static android.os.BatteryManager.BATTERY_PLUGGED_ANY;
|
||||
|
||||
import static com.android.cts.net.hostside.NetworkPolicyTestUtils.executeShellCommand;
|
||||
import static com.android.cts.net.hostside.NetworkPolicyTestUtils.forceRunJob;
|
||||
|
|
@ -119,10 +117,6 @@ public abstract class AbstractRestrictBackgroundNetworkTestCase {
|
|||
protected static final String NOTIFICATION_TYPE_ACTION_BUNDLE = "ACTION_BUNDLE";
|
||||
protected static final String NOTIFICATION_TYPE_ACTION_REMOTE_INPUT = "ACTION_REMOTE_INPUT";
|
||||
|
||||
// TODO: Update BatteryManager.BATTERY_PLUGGED_ANY as @TestApi
|
||||
public static final int BATTERY_PLUGGED_ANY =
|
||||
BATTERY_PLUGGED_AC | BATTERY_PLUGGED_USB | BATTERY_PLUGGED_WIRELESS;
|
||||
|
||||
private static final String NETWORK_STATUS_SEPARATOR = "\\|";
|
||||
private static final int SECOND_IN_MS = 1000;
|
||||
static final int NETWORK_TIMEOUT_MS = 15 * SECOND_IN_MS;
|
||||
|
|
|
|||
Loading…
Reference in a new issue