Boostrap test for NetworkMonitor
This will finally allow to write captive portal detection unit tests. Bug: 32561414 Bug: 62918393 Test: runtest frameworks-net Change-Id: I38db1bb79ae80a82b4199dc9cb1b56257e0cf222
This commit is contained in:
@@ -278,6 +278,10 @@ public class NetworkAgentInfo implements Comparable<NetworkAgentInfo> {
|
|||||||
return mHandler;
|
return mHandler;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Network network() {
|
||||||
|
return network;
|
||||||
|
}
|
||||||
|
|
||||||
// Functions for manipulating the requests satisfied by this network.
|
// Functions for manipulating the requests satisfied by this network.
|
||||||
//
|
//
|
||||||
// These functions must only called on ConnectivityService's main thread.
|
// These functions must only called on ConnectivityService's main thread.
|
||||||
|
|||||||
@@ -683,7 +683,8 @@ public class ConnectivityServiceTest extends AndroidTestCase {
|
|||||||
public WrappedNetworkMonitor(Context context, Handler handler,
|
public WrappedNetworkMonitor(Context context, Handler handler,
|
||||||
NetworkAgentInfo networkAgentInfo, NetworkRequest defaultRequest,
|
NetworkAgentInfo networkAgentInfo, NetworkRequest defaultRequest,
|
||||||
IpConnectivityLog log) {
|
IpConnectivityLog log) {
|
||||||
super(context, handler, networkAgentInfo, defaultRequest, log);
|
super(context, handler, networkAgentInfo, defaultRequest, log,
|
||||||
|
NetworkMonitor.NetworkMonitorSettings.DEFAULT);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user