docs: Added CL commands for data-saver testing am: b603eae9b3
am: 2d05938af9
* commit '2d05938af9e572ca9582552ad966c18b7b83e94f':
docs: Added CL commands for data-saver testing
Change-Id: Ic0f9a82f05dc32b162013df51c155f2a1a206c45
This commit is contained in:
@@ -179,10 +179,13 @@ if (connMgr.isActiveNetworkMetered()) {
|
|||||||
Testing with Android Debug Bridge Commands
|
Testing with Android Debug Bridge Commands
|
||||||
</h2>
|
</h2>
|
||||||
|
|
||||||
The <a href="{@docRoot}tools/help/adb.html">Android Debug Bridge (ADB)</a>
|
<p>
|
||||||
provides a few commands that you can use to check and configure network
|
The <a href="{@docRoot}tools/help/adb.html">Android Debug Bridge (ADB)</a>
|
||||||
permissions:
|
provides a few commands that you can use to test your app in Data Saver
|
||||||
|
conditions. You can check and configure network
|
||||||
|
permissions or set wireless networks as metered to test your app on unmetered
|
||||||
|
networks.
|
||||||
|
</p>
|
||||||
<dl>
|
<dl>
|
||||||
<dt>
|
<dt>
|
||||||
<code>$ adb shell dumpsys netpolicy</code>
|
<code>$ adb shell dumpsys netpolicy</code>
|
||||||
@@ -231,4 +234,23 @@ permissions:
|
|||||||
Removes the specified package UID from the whitelist to block background
|
Removes the specified package UID from the whitelist to block background
|
||||||
metered data usage while Data Saver is enabled.
|
metered data usage while Data Saver is enabled.
|
||||||
</dd>
|
</dd>
|
||||||
|
|
||||||
|
<dt>
|
||||||
|
<code>$ adb shell cmd netpolicy list wifi-networks</code>
|
||||||
|
</dt>
|
||||||
|
|
||||||
|
<dd>
|
||||||
|
Lists all wifi networks, displaying whether they're metered.
|
||||||
|
</dd>
|
||||||
|
|
||||||
|
|
||||||
|
<dt>
|
||||||
|
<code>$ adb shell cmd netpolicy set metered-network <WIFI_SSID>
|
||||||
|
true</code>
|
||||||
|
</dt>
|
||||||
|
|
||||||
|
<dd>
|
||||||
|
Sets wifi with the specified SSID as metered, allowing you to simulate a
|
||||||
|
metered network on an unmetered network.
|
||||||
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
Reference in New Issue
Block a user