/packages/modules/AdServices/shared/libraries/device-side/java/com/android/adservices/mockito/ |
D | AndroidExtendedMockitoMocker.java | 26 import com.android.modules.utils.build.SdkLevel; 60 assertSpiedOrMocked(SdkLevel.class); in mockIsAtLeastR() 61 doReturn(isIt).when(SdkLevel::isAtLeastR); in mockIsAtLeastR() 67 assertSpiedOrMocked(SdkLevel.class); in mockIsAtLeastS() 68 doReturn(isIt).when(SdkLevel::isAtLeastS); in mockIsAtLeastS() 74 assertSpiedOrMocked(SdkLevel.class); in mockIsAtLeastT() 75 doReturn(isIt).when(SdkLevel::isAtLeastT); in mockIsAtLeastT() 81 assertSpiedOrMocked(SdkLevel.class); in mockSdkLevelR() 82 doReturn(true).when(SdkLevel::isAtLeastR); in mockSdkLevelR() 83 doReturn(false).when(SdkLevel::isAtLeastS); in mockSdkLevelR() [all …]
|
/packages/modules/Permission/SafetyCenter/Config/tests/java/com/android/safetycenter/config/ |
D | ParserConfigInvalidTest.kt | 21 import com.android.modules.utils.build.SdkLevel 71 SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi() in parameters() 84 SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi() in parameters() 97 SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi() in parameters() 189 SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi() in parameters() 202 SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi() in parameters() 269 SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi() in parameters() 337 SdkLevel.isAtLeastU() in parameters() 345 SdkLevel.isAtLeastU() in parameters() 378 SdkLevel.isAtLeastU() in parameters() [all …]
|
/packages/modules/SdkExtensions/javatests/com/android/os/ext/ |
D | SdkExtensionsTest.java | 49 import com.android.modules.utils.build.SdkLevel; 79 if (SdkLevel.isAtLeastU()) { in assertAtLeastBaseVersion() 81 } else if (SdkLevel.isAtLeastT()) { in assertAtLeastBaseVersion() 83 } else if (SdkLevel.isAtLeastS()) { in assertAtLeastBaseVersion() 166 if (SdkLevel.isAtLeastS()) { in testGetAllExtensionVersionsKeys() 169 if (SdkLevel.isAtLeastT()) { in testGetAllExtensionVersionsKeys() 173 if (SdkLevel.isAtLeastU()) { in testGetAllExtensionVersionsKeys() 176 if (SdkLevel.isAtLeastV()) { in testGetAllExtensionVersionsKeys() 191 Expectation expectation = dessertExpectation(SdkLevel.isAtLeastS()); in testExtensionS() 197 Expectation expectation = dessertExpectation(SdkLevel.isAtLeastT()); in testExtensionT() [all …]
|
/packages/modules/Permission/tests/cts/safetycenter/src/android/safetycenter/cts/config/ |
D | SafetySourceTest.kt | 27 import com.android.modules.utils.build.SdkLevel 367 if (SdkLevel.isAtLeastU()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 390 if (SdkLevel.isAtLeastU()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 395 if (SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 423 if (SdkLevel.isAtLeastU()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 428 if (SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 449 if (SdkLevel.isAtLeastU()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 454 if (SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 475 if (SdkLevel.isAtLeastU()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() 480 if (SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi()) { in equalsHashCodeToString_usingEqualsHashCodeToStringTester() [all …]
|
/packages/apps/DocumentsUI/tests/unit/com/android/documentsui/ |
D | UserManagerStateTest.java | 51 import com.android.modules.utils.build.SdkLevel; 97 if (SdkLevel.isAtLeastV()) { in setup() 140 if (SdkLevel.isAtLeastR()) { in setup() 168 if (!SdkLevel.isAtLeastV()) return; in testGetUserIds_allProfilesCurrentUserSystem_allShowInSharingSurfacesSeparate() 182 if (!SdkLevel.isAtLeastV()) return; in testGetUserIds_allProfilesCurrentUserManaged_allShowInSharingSurfacesSeparate() 196 if (!SdkLevel.isAtLeastV()) return; in testGetUserIds_allProfilesCurrentUserPrivate_allShowInSharingSurfacesSeparate() 229 if (!SdkLevel.isAtLeastV()) return; in testGetUserIds_systemAndPrivateUserCurrentUserSystem_returnsBoth() 240 if (!SdkLevel.isAtLeastV()) return; in testGetUserIds_systemAndPrivateUserCurrentUserPrivate_returnsBoth() 251 if (SdkLevel.isAtLeastV()) return; in testGetUserIds_systemAndOtherUserCurrentUserOtherPreV_returnsCurrentUser() 262 if (!SdkLevel.isAtLeastV()) return; in testGetUserIds_systemAndOtherUserCurrentUserOtherPostV_returnsSystemUser() [all …]
|
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/permission/utils/v35/ |
D | MultiDeviceUtils.kt | 32 import com.android.modules.utils.build.SdkLevel in <lambda>() 56 SdkLevel.isAtLeastV() && in <lambda>() 68 if (!SdkLevel.isAtLeastV()) { in <lambda>() 90 if (!SdkLevel.isAtLeastV() || deviceId == ContextCompat.DEVICE_ID_DEFAULT) { in <lambda>() 107 !SdkLevel.isAtLeastV() || in <lambda>() 115 !SdkLevel.isAtLeastV() || in <lambda>() 132 if (!SdkLevel.isAtLeastV()) { in <lambda>() 162 if (!SdkLevel.isAtLeastV() || isDefaultDeviceId(persistentDeviceId)) { in <lambda>() 201 if (!SdkLevel.isAtLeastV() || isDefaultDeviceId(persistentDeviceId)) { in <lambda>() 249 if (!SdkLevel.isAtLeastV() || isDefaultDeviceId(persistentDeviceId)) { in <lambda>() [all …]
|
/packages/apps/DocumentsUI/tests/unit/com/android/documentsui/sidebar/ |
D | UserItemsCombinerTest.java | 34 import com.android.modules.utils.build.SdkLevel; 103 if (SdkLevel.isAtLeastV()) { in setUp() 124 if (SdkLevel.isAtLeastV()) { in testCreatePresentableListForAllUsers_empty() 161 if (SdkLevel.isAtLeastV()) { in testCreatePresentableListForAllUsers_currentIsPersonal_personalItemsOnly() 177 if (SdkLevel.isAtLeastV()) { in testCreatePresentableListForAllUsers_currentIsWork_personalItemsOnly() 191 if (!SdkLevel.isAtLeastV()) return; in testCreatePresentableListForAllUsers_currentIsPrivate_personalItemsOnly() 233 if (SdkLevel.isAtLeastV()) { in testCreatePresentableListForAllUsers_currentIsPersonal_workItemsOnly() 250 if (SdkLevel.isAtLeastV()) { in testCreatePresentableListForAllUsers_currentIsWork_workItemsOnly() 264 if (!SdkLevel.isAtLeastV()) return; in testCreatePresentableListForAllUsers_currentIsPrivate_workItemsOnly() 320 if (SdkLevel.isAtLeastV()) { in testCreatePresentableListForAllUsers_currentIsPersonal_allUsersItems() [all …]
|
/packages/modules/AdServices/adservices/tests/unittest/service-core/src/com/android/adservices/service/measurement/ |
D | MeasurementImplTest.java | 80 import com.android.modules.utils.build.SdkLevel; 110 .mockStatic(SdkLevel.class) 445 Assume.assumeTrue(SdkLevel.isAtLeastT()); in testDeleteRegistrations_success_recordsDeletionInSystemServer() 463 Assume.assumeTrue(!SdkLevel.isAtLeastT()); in testDeleteRegistrations_success_recordsDeletion_S() 464 Assume.assumeTrue(SdkLevel.isAtLeastS()); in testDeleteRegistrations_success_recordsDeletion_S() 477 Assume.assumeTrue(!SdkLevel.isAtLeastS()); in testDeleteRegistrations_success_recordsDeletion_R() 507 ExtendedMockito.doReturn(false).when(SdkLevel::isAtLeastT); in testDeleteRegistrations_success_recordsDeletionInAppSearch_flagOff_S() 508 ExtendedMockito.doReturn(true).when(SdkLevel::isAtLeastS); in testDeleteRegistrations_success_recordsDeletionInAppSearch_flagOff_S() 520 ExtendedMockito.doReturn(false).when(SdkLevel::isAtLeastS); in testDeleteRegistrations_success_recordsDeletionInAppSearch_flagOff_R() 561 Assume.assumeTrue(SdkLevel.isAtLeastT()); in testDeletePackageRecords_success_recordsDeletionInSystemServer() [all …]
|
/packages/modules/Wifi/framework/tests/src/android/net/wifi/ |
D | WifiInfoTest.java | 39 import com.android.modules.utils.build.SdkLevel; 166 if (SdkLevel.isAtLeastT()) { in makeWifiInfoForRedactionTest() 169 if (SdkLevel.isAtLeastV()) { in makeWifiInfoForRedactionTest() 209 if (SdkLevel.isAtLeastS()) { in assertNoRedaction() 216 if (SdkLevel.isAtLeastT()) { in assertNoRedaction() 219 if (SdkLevel.isAtLeastV()) { in assertNoRedaction() 247 if (SdkLevel.isAtLeastS()) { in testWifiInfoRedactNoRedactions() 274 if (SdkLevel.isAtLeastS()) { in assertLocationSensitiveRedaction() 282 if (SdkLevel.isAtLeastT()) { in assertLocationSensitiveRedaction() 310 if (SdkLevel.isAtLeastS()) { in testWifiInfoRedactLocationSensitiveInfo() [all …]
|
D | SoftApConfigurationTest.java | 41 import com.android.modules.utils.build.SdkLevel; 116 if (SdkLevel.isAtLeastS()) { in testBasicSettings() 123 if (SdkLevel.isAtLeastT()) { in testBasicSettings() 148 assumeTrue(SdkLevel.isAtLeastT()); in testSetWifiSsid() 221 if (SdkLevel.isAtLeastS()) { in testWpa2WithAllFieldCustomized() 228 if (SdkLevel.isAtLeastT()) { in testWpa2WithAllFieldCustomized() 248 if (SdkLevel.isAtLeastS()) { in testWpa2WithAllFieldCustomized() 258 if (SdkLevel.isAtLeastT()) { in testWpa2WithAllFieldCustomized() 331 assumeTrue(SdkLevel.isAtLeastT()); in testWpa3OweTransition() 363 assumeTrue(SdkLevel.isAtLeastT()); in testWpa3Owe() [all …]
|
D | SoftApInfoTest.java | 28 import com.android.modules.utils.build.SdkLevel; 59 if (SdkLevel.isAtLeastV()) { in testCopyOperator() 80 if (SdkLevel.isAtLeastV()) { in testParcelOperation() 107 if (SdkLevel.isAtLeastS()) { in testInitialValue() 112 if (SdkLevel.isAtLeastV()) { in testInitialValue() 131 if (SdkLevel.isAtLeastS()) { in testGetXXXAlignedWithSetXXX() 137 if (SdkLevel.isAtLeastV()) { in testGetXXXAlignedWithSetXXX()
|
/packages/modules/Connectivity/service-t/src/com/android/server/ |
D | ConnectivityServiceInitializer.java | 25 import com.android.modules.utils.build.SdkLevel; 120 if (!SdkLevel.isAtLeastT()) return null; in createIpSecService() 129 if (!SdkLevel.isAtLeastT()) return null; in createConnectivityNativeService() 140 if (!SdkLevel.isAtLeastT()) return null; in createNsdService() 147 if (!SdkLevel.isAtLeastT()) return null; in createNearbyService() 163 if (!SdkLevel.isAtLeastT() || !mConnectivity.deviceSupportsEthernet(context)) { in createEthernetService() 181 if (!SdkLevel.isAtLeastU()) { in createThreadNetworkService() 184 if (!SdkLevel.isAtLeastV() && !pm.hasSystemFeature(PackageManager.FEATURE_LEANBACK)) { in createThreadNetworkService()
|
/packages/modules/ConfigInfrastructure/service/javatests/src/com/android/server/deviceconfig/ |
D | UnattendedRebootManagerTest.java | 51 import com.android.modules.utils.build.SdkLevel; 85 assumeTrue(SdkLevel.isAtLeastV()); in setUp() 155 assumeTrue(SdkLevel.isAtLeastV()); in maybePrepareUnattendedReboot() 168 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot() 190 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot_requiresCharging_notCharging() 228 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot_doesNotRequireCharging_notCharging() 255 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot_requiresCharging_flagNotEnabled() 282 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot_noPinLock() 303 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot_noPreparation() 323 assumeTrue(SdkLevel.isAtLeastV()); in scheduleReboot_simPinPreparationFailed() [all …]
|
/packages/modules/Permission/framework-s/java/android/safetycenter/config/ |
D | SafetySource.java | 38 import com.android.modules.utils.build.SdkLevel; 180 if (SdkLevel.isAtLeastU()) { 188 if (SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi()) { 308 if (!SdkLevel.isAtLeastU()) { in getOptionalPackageName() 374 if (!SdkLevel.isAtLeastV()) { in getTitleForPrivateProfileResId() 531 if (!SdkLevel.isAtLeastU()) { in areNotificationsAllowed() 547 if (!SdkLevel.isAtLeastU()) { in getDeduplicationGroup() 570 if (!SdkLevel.isAtLeastU()) { in getPackageCertificateHashes() 683 if (SdkLevel.isAtLeastU()) { in writeToParcel() 688 if (SdkLevel.isAtLeastV() && Flags.privateProfileTitleApi()) { in writeToParcel() [all …]
|
/packages/modules/AdServices/adservices/tests/unittest/service-core/src/com/android/adservices/service/common/compat/ |
D | ServiceCompatUtilsTest.java | 29 import com.android.modules.utils.build.SdkLevel; 49 .mockStatic(SdkLevel.class) in setUp() 61 doReturn(false).when(SdkLevel::isAtLeastT); in testShouldDisableJob_S() 68 doReturn(true).when(SdkLevel::isAtLeastT); in testShouldDisableJob_T_NonExtPackageName() 75 doReturn(true).when(SdkLevel::isAtLeastT); in testShouldDisableJob_T_ExtPackageName() 82 doReturn(true).when(SdkLevel::isAtLeastT); in testShouldDisableJob_T_ExtPackageNameButNotSuffix()
|
D | BuildCompatUtilsTest.java | 32 import com.android.modules.utils.build.SdkLevel; 42 Assume.assumeTrue(SdkLevel.isAtLeastS()); in testIsDebuggable_SPlus_debuggable() 64 Assume.assumeTrue(SdkLevel.isAtLeastS()); in testIsDebuggable_SPlus_notDebuggable() 88 .mockStatic(SdkLevel.class) in testIsDebuggable_RMinus_debuggable() 93 doReturn(false).when(SdkLevel::isAtLeastS); in testIsDebuggable_RMinus_debuggable() 108 .mockStatic(SdkLevel.class) in testIsDebuggable_RMinus_notDebuggable() 113 doReturn(false).when(SdkLevel::isAtLeastS); in testIsDebuggable_RMinus_notDebuggable()
|
D | ProcessCompatUtilsTest.java | 24 import com.android.modules.utils.build.SdkLevel; 42 .mockStatic(SdkLevel.class) in setUp() 54 ExtendedMockito.doReturn(false).when(SdkLevel::isAtLeastT); in testIsSdkSandboxUid_onSMinus_notSdkSandboxUid() 60 Assume.assumeTrue(SdkLevel.isAtLeastT()); in testIsSdkSandboxUid_onTPlus_sdkSandboxUId() 67 Assume.assumeTrue(SdkLevel.isAtLeastT()); in testIsSdkSandboxUid_onTPlus_notSdkSandboxUId()
|
/packages/modules/Wifi/framework/java/android/net/wifi/ |
D | SoftApConfiguration.java | 41 import com.android.modules.utils.build.SdkLevel; 709 if (SdkLevel.isAtLeastT()) { in readOuiKeyedDataList() 793 if (!SdkLevel.isAtLeastT()) { in getVendorElements() 904 if (!SdkLevel.isAtLeastS()) { in getChannels() 1012 if (!SdkLevel.isAtLeastS()) { in getMacRandomizationSetting() 1035 if (!SdkLevel.isAtLeastS()) { in isBridgedModeOpportunisticShutdownEnabled() 1067 if (!SdkLevel.isAtLeastS()) { in isIeee80211axEnabled() 1083 if (!SdkLevel.isAtLeastT()) { in isIeee80211beEnabled() 1106 if (!SdkLevel.isAtLeastT()) { in getAllowedAcsChannels() 1131 if (!SdkLevel.isAtLeastT()) { in getMaxChannelBandwidth() [all …]
|
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/permission/utils/ |
D | PermissionMapping.kt | 26 import com.android.modules.utils.build.SdkLevel 51 if (!SdkLevel.isAtLeastT()) listOf() 99 if (!SdkLevel.isAtLeastT()) { 104 if (SdkLevel.isAtLeastT()) { 115 if (SdkLevel.isAtLeastU()) { 127 if (SdkLevel.isAtLeastS()) { 137 if (SdkLevel.isAtLeastT()) { 163 if (SdkLevel.isAtLeastS()) { 172 if (SdkLevel.isAtLeastS()) { 179 if (SdkLevel.isAtLeastT()) { [all …]
|
/packages/modules/AdServices/adservices/apk/tests/settings/src/com/android/adservices/ui/settings/ |
D | ConsentSettingsUiAutomatorTest.java | 33 import com.android.modules.utils.build.SdkLevel; 57 Assume.assumeTrue(SdkLevel.isAtLeastT()); in consentSystemServerOnlyTest() 75 Assume.assumeTrue(SdkLevel.isAtLeastT()); in consentSystemServerAndPpApiTest() 84 Assume.assumeTrue(SdkLevel.isAtLeastT()); in consentSystemServerOnlyDialogsOnTest() 102 Assume.assumeTrue(SdkLevel.isAtLeastT()); in consentSystemServerAndPpApiDialogsOnTest() 112 Assume.assumeTrue(!SdkLevel.isAtLeastT()); in consentAppSearchOnlyTest() 124 Assume.assumeTrue(!SdkLevel.isAtLeastT()); in consentAppSearchOnlyDialogsOnTest()
|
/packages/modules/Wifi/framework/tests/src/android/net/wifi/p2p/ |
D | WifiP2pGroupTest.java | 32 import com.android.modules.utils.build.SdkLevel; 78 if (SdkLevel.isAtLeastV()) { in testSetterGetter() 83 if (SdkLevel.isAtLeastV()) { in testSetterGetter() 94 if (SdkLevel.isAtLeastV()) { in testSetterGetter() 106 if (SdkLevel.isAtLeastV()) { in testSetterGetter() 111 if (SdkLevel.isAtLeastV()) { in testSetterGetter() 132 if (SdkLevel.isAtLeastV()) { in testSetterGetter()
|
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/permission/utils/v31/ |
D | AdminRestrictedPermissionsUtils.java | 27 import com.android.modules.utils.build.SdkLevel; 49 if (SdkLevel.isAtLeastS()) { 54 if (SdkLevel.isAtLeastT()) { 63 if (!SdkLevel.isAtLeastS()) { in mayAdminGrantPermission() 85 if (!SdkLevel.isAtLeastS()) { in mayAdminGrantPermission() 104 return SdkLevel.isAtLeastU() && dpm.isOrganizationOwnedDeviceWithManagedProfile() in mayManagedProfileAdminGrantReadSms()
|
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/ |
D | InsecureEapNetworkHandlerTest.java | 56 import com.android.modules.utils.build.SdkLevel; 410 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseAcceptWhenConnectByUser() 427 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseRejectWhenConnectByUser() 444 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseAcceptWhenConnectByAutoConnect() 461 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseRejectWhenConnectByAutoConnect() 478 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseTapWhenConnectByAutoConnect() 494 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseWhenTrustOnFirstUseNoPendingCert() 512 assumeTrue(SdkLevel.isAtLeastT()); in verifyTrustOnFirstUseWhenTrustOnFirstUseNotSupported() 528 assumeFalse(SdkLevel.isAtLeastT()); in verifyLegacyEapNetworkAcceptWhenConnectByUser() 546 assumeFalse(SdkLevel.isAtLeastT()); in verifyLegacyEapNetworkRejectWhenConnectByUser() [all …]
|
/packages/apps/DocumentsUI/tests/unit/com/android/documentsui/dirlist/ |
D | IconHelperTest.java | 32 import com.android.modules.utils.build.SdkLevel; 71 isPrivateSpaceEnabled = SdkLevel.isAtLeastS() && isPrivateSpaceEnabled; in setUp() 72 if (SdkLevel.isAtLeastS()) { in setUp() 74 mTestUserManagerState.userIds = SdkLevel.isAtLeastV() in setUp() 100 if (!SdkLevel.isAtLeastV() || !isPrivateSpaceEnabled) return; in testShouldShowBadge_returnTrue_onPrivateUser() 131 if (SdkLevel.isAtLeastS()) { in testShouldShowBadge_returnFalseOnManagedUser_withoutMultipleUsers() 141 if (!SdkLevel.isAtLeastV() || !isPrivateSpaceEnabled) return; in testShouldShowBadge_returnFalseOnPrivateUser_withoutMultipleUsers()
|
/packages/modules/Connectivity/tests/cts/net/src/android/net/cts/ |
D | TestUtils.java | 21 import com.android.modules.utils.build.SdkLevel; 34 return SdkLevel.isAtLeastS() && ConstantsShim.VERSION > Build.VERSION_CODES.R; in shouldTestSApis() 42 return SdkLevel.isAtLeastT() && ConstantsShim.VERSION > Build.VERSION_CODES.S_V2; in shouldTestTApis() 50 return SdkLevel.isAtLeastU() && ConstantsShim.VERSION > Build.VERSION_CODES.TIRAMISU; in shouldTestUApis()
|