summaryrefslogtreecommitdiff
path: root/tests/unit/java/android/net/NetworkStatsCollectionTest.java
diff options
context:
space:
mode:
authorHungming Chen <nuccachen@google.com>2021-12-17 17:24:58 +0800
committerHungming Chen <nuccachen@google.com>2022-01-20 22:50:12 +0800
commit2f623f381c823c6c3fe3446993089bee78c65d4d (patch)
tree3f3c41833dad73ad8c8dfa4e6f37fa3d11bf9c60 /tests/unit/java/android/net/NetworkStatsCollectionTest.java
parent6139d87623705116a6cff7da5fdb9c88831ca6ae (diff)
[CLATJ#4] libclat: move selectIpv4Address() and isIpv4AddressFree() from netd to apex
isIpv4AddressFree() is moved from ClatdController without behavior change. selectIpv4Address() and its test are moved from ClatdController as well. They have been refactored slightly for testing because function pointer of isIpv4AddressFreeFunc is not a global variable anymore. We can't set global function pointer to change selectIpv4Address() behavior for testing. Instead isIpv4AddressFree is sent as an argument of function pointer. For public caller, selectIpv4Address() has no behavior change. For test caller, they can call an internal selectIpv4AddressInternal (.., fn) to change isIpv4AddrFreeFn function pointer for testing. Bug: 212345928 Test: build and boot atest libclat_test Change-Id: Iab5e6fd5ebbccf10e7b3be2251b45949cf3f3464
Diffstat (limited to 'tests/unit/java/android/net/NetworkStatsCollectionTest.java')
0 files changed, 0 insertions, 0 deletions