Mark VisibleForTesting members as public

Package-private members are not visible across jars; with the latest
refactoring of build and jarjar rules for connectivity, tests fail as
the utils are picked up from the on-device module rather than the test
package, and such members could not be found.

Bug: 204830222
Test: atest ConnectivityCoverageTests
Change-Id: Ia62b01e2e3123a2d8a432c061e3c576c86356df5
This commit is contained in:
Remi NGUYEN VAN 2022-01-31 21:55:43 +09:00
commit 5c080dc85b
2 changed files with 3 additions and 3 deletions

View file

@ -85,7 +85,7 @@ public final class NetworkCapabilitiesUtils {
* and {@code FORCE_RESTRICTED_CAPABILITIES}.
*/
@VisibleForTesting
static final long RESTRICTED_CAPABILITIES = packBitList(
public static final long RESTRICTED_CAPABILITIES = packBitList(
NET_CAPABILITY_BIP,
NET_CAPABILITY_CBS,
NET_CAPABILITY_DUN,
@ -115,7 +115,7 @@ public final class NetworkCapabilitiesUtils {
* See {@code NetworkCapabilities#maybeMarkCapabilitiesRestricted}.
*/
@VisibleForTesting
static final long UNRESTRICTED_CAPABILITIES = packBitList(
public static final long UNRESTRICTED_CAPABILITIES = packBitList(
NET_CAPABILITY_INTERNET,
NET_CAPABILITY_MMS,
NET_CAPABILITY_SUPL,

View file

@ -116,7 +116,7 @@ public class NetworkStatsUtils {
}
@VisibleForTesting
static android.net.NetworkStats.Entry fromBucket(NetworkStats.Bucket bucket) {
public static android.net.NetworkStats.Entry fromBucket(NetworkStats.Bucket bucket) {
return new android.net.NetworkStats.Entry(
null /* IFACE_ALL */, bucket.getUid(), convertBucketState(bucket.getState()),
convertBucketTag(bucket.getTag()), convertBucketMetered(bucket.getMetered()),