[FUI09] Expose NetworkStateSnapshot as system API
This is needed by NetworkStatsService and NetworkPolicyManagerService to utilize the snapshots of information of networks that grabbed from ConnectivityService. Test: atest FrameworksNetTests NetworkPolicyManagerServiceTest Bug: 174123988 Change-Id: I7e974ef7b23ba9ba6ee775eed9899b0c0e2eca55
This commit is contained in:
@@ -63,10 +63,10 @@ class NetworkStateSnapshotTest {
|
||||
|
||||
@Test
|
||||
fun testParcelUnparcel() {
|
||||
val emptySnapshot = NetworkStateSnapshot(LinkProperties(), NetworkCapabilities(),
|
||||
Network(TEST_NETID), null, TYPE_NONE)
|
||||
val emptySnapshot = NetworkStateSnapshot(Network(TEST_NETID), NetworkCapabilities(),
|
||||
LinkProperties(), null, TYPE_NONE)
|
||||
val snapshot = NetworkStateSnapshot(
|
||||
TEST_LINK_PROPERTIES, TEST_CAPABILITIES, Network(TEST_NETID), TEST_IMSI, TYPE_WIFI)
|
||||
Network(TEST_NETID), TEST_CAPABILITIES, TEST_LINK_PROPERTIES, TEST_IMSI, TYPE_WIFI)
|
||||
assertParcelSane(emptySnapshot, 5)
|
||||
assertParcelSane(snapshot, 5)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user