Home
last modified time | relevance | path

Searched refs:DeviceUtils (Results 1 – 25 of 57) sorted by relevance

123

/packages/modules/HealthFitness/tests/cts/hostsidetests/healthconnect/host/src/util/
DHostSideTestUtil.java20 import android.cts.statsdatom.lib.DeviceUtils;
62 DeviceUtils.runDeviceTests(device, TEST_APP_PKG_NAME, className, testName); in triggerTestInTestApp()
125 return !DeviceUtils.hasFeature(device, FEATURE_TV) in isHardwareSupported()
126 && !DeviceUtils.hasFeature(device, FEATURE_EMBEDDED) in isHardwareSupported()
127 && !DeviceUtils.hasFeature(device, FEATURE_WATCH) in isHardwareSupported()
128 && !DeviceUtils.hasFeature(device, FEATURE_LEANBACK) in isHardwareSupported()
129 && !DeviceUtils.hasFeature(device, FEATURE_AUTOMOTIVE); in isHardwareSupported()
139 DeviceUtils.getDeviceConfigFeature( in setupRateLimitingFeatureFlag()
142 DeviceUtils.putDeviceConfigFeature( in setupRateLimitingFeatureFlag()
149 DeviceUtils.deleteDeviceConfigFeature( in restoreRateLimitingFeatureFlag()
[all …]
/packages/modules/StatsD/tests/src/android/cts/statsd/validation/
DDirectoryValidationTest.java6 import android.cts.statsdatom.lib.DeviceUtils;
24 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
31 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
41 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testStatsActiveMetricDirectoryExists()
46 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testStatsDataDirectoryExists()
51 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testStatsMetadataDirectoryExists()
56 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testStatsServiceDirectoryExists()
61 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testTrainInfoDirectoryExists()
DValidationTests.java24 import android.cts.statsdatom.lib.DeviceUtils;
82 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
85 DeviceUtils.turnBatteryStatsAutoResetOff( in setUp()
93 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
94 DeviceUtils.resetBatteryStatus(getDevice()); in tearDown()
95 DeviceUtils.turnScreenOn(getDevice()); in tearDown()
96 DeviceUtils.turnBatteryStatsAutoResetOn(getDevice()); in tearDown()
110 if (!DeviceUtils.hasFeature(getDevice(), FEATURE_AUTOMOTIVE)) return; in testPartialWakelock()
112 DeviceUtils.unplugDevice(getDevice()); in testPartialWakelock()
113 DeviceUtils.flushBatteryStatsHandlers(getDevice()); in testPartialWakelock()
[all …]
DStatsFrameworkInitializerTest.java22 import android.cts.statsdatom.lib.DeviceUtils;
37 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
44 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
55 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testStatsFrameworkInitializer_failsWhenCalledOutsideOfSystemServiceRegistry()
DProcStatsValidationTests.java24 import android.cts.statsdatom.lib.DeviceUtils;
56 DeviceUtils.turnScreenOff(getDevice()); in toggleScreenAndSleep()
58 DeviceUtils.turnScreenOn(getDevice()); in toggleScreenAndSleep()
70 DeviceUtils.executeBackgroundService(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testProcessStateByPulling()
77 DeviceUtils.executeBackgroundService(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testProcessStateByPulling()
87 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in testProcessStateByPulling()
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/permission/ui/
DManagePermissionsActivity.java60 import com.android.permissioncontroller.DeviceUtils;
152 if (DeviceUtils.isAuto(this)) { in onCreate()
164 if ((DeviceUtils.isTelevision(this) || DeviceUtils.isAuto(this)) in onCreate()
211 if (DeviceUtils.isAuto(this)) { in onCreate()
214 } else if (DeviceUtils.isTelevision(this)) { in onCreate()
235 if (DeviceUtils.isAuto(this)) { in onCreate()
237 } else if (DeviceUtils.isWear(this)) { in onCreate()
257 if (DeviceUtils.isAuto(this)) { in onCreate()
260 } else if (DeviceUtils.isWear(this)) { in onCreate()
272 if (DeviceUtils.isAuto(this) || DeviceUtils.isTelevision(this)) { in onCreate()
[all …]
DSettingsActivity.java19 import com.android.permissioncontroller.DeviceUtils;
28 return super.isSettingsTransitionEnabled() && !(DeviceUtils.isAuto(this) in isSettingsTransitionEnabled()
29 || DeviceUtils.isTelevision(this) || DeviceUtils.isWear(this)); in isSettingsTransitionEnabled()
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/permission/ui/legacy/
DAppPermissionActivity.java37 import com.android.permissioncontroller.DeviceUtils;
77 if (!DeviceUtils.isAuto(this) && !DeviceUtils.isWear(this) in onCreate()
78 && !DeviceUtils.isTelevision(this)) { in onCreate()
82 if (DeviceUtils.isAuto(this)) { in onCreate()
150 if (DeviceUtils.isAuto(this)) { in onCreate()
163 } else if (DeviceUtils.isTelevision(this)) { in onCreate()
180 if (DeviceUtils.isAuto(this)) { in onOptionsItemSelected()
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/role/ui/
DSettingsActivity.java24 import com.android.permissioncontroller.DeviceUtils;
43 return super.isSettingsTransitionEnabled() && !(DeviceUtils.isAuto(this) in isSettingsTransitionEnabled()
44 || DeviceUtils.isTelevision(this) || DeviceUtils.isWear(this)); in isSettingsTransitionEnabled()
DDefaultAppListActivity.java24 import com.android.permissioncontroller.DeviceUtils;
37 if (DeviceUtils.isAuto(this)) { in onCreate()
47 if (DeviceUtils.isAuto(this)) { in onCreate()
49 } else if (DeviceUtils.isWear(this)) { in onCreate()
DDefaultAppActivity.java30 import com.android.permissioncontroller.DeviceUtils;
64 if (DeviceUtils.isAuto(this)) { in onCreate()
99 if (DeviceUtils.isAuto(this)) { in onCreate()
101 } else if (DeviceUtils.isWear(this)) { in onCreate()
/packages/modules/Permission/tests/hostside/safetycenter/src/android/safetycenter/hostside/rules/
DHelperAppRule.kt19 import android.cts.statsdatom.lib.DeviceUtils
39 DeviceUtils.installTestApp( in apply()
47 DeviceUtils.uninstallTestApp(hostTestClass.device, packageName) in apply()
55 DeviceUtils.runDeviceTests(hostTestClass.device, packageName, testClassName, testMethodName) in runTest()
/packages/modules/StatsD/tests/src/android/cts/statsd/restricted/
DReadRestrictedStatsPermissionTest.java6 import android.cts.statsdatom.lib.DeviceUtils;
24 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
31 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
41 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testReadRestrictedStatsPermission()
/packages/modules/StatsD/tests/src/android/cts/statsd/metadata/
DMetadataTests.java24 import android.cts.statsdatom.lib.DeviceUtils;
128 DeviceUtils.runDeviceTests(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE, in testAtomLossInfoCollection()
177 DeviceUtils.runDeviceTests( in testSystemServerLossErrorCode()
252 DeviceUtils.uninstallTestApp(getDevice(), testPkgName); in testAtomIdLossDistributionCollection()
254 DeviceUtils.installTestApp(getDevice(), testApk, testPkgName, mCtsBuild); in testAtomIdLossDistributionCollection()
267 DeviceUtils.uninstallTestApp(getDevice(), testPkgName); in testAtomIdLossDistributionCollection()
275 DeviceUtils.uninstallTestApp(getDevice(), testPkgName); in testAtomIdLossDistributionCollection()
287 DeviceUtils.runDeviceTests(getDevice(), pkg, cls, test); in runTestUntilLossAtomReported()
DMetadataTestCase.java24 import android.cts.statsdatom.lib.DeviceUtils;
71 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
80 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
/packages/modules/StatsD/tests/src/android/cts/statsd/uidmap/
DUidMapTests.java23 import android.cts.statsdatom.lib.DeviceUtils;
54 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
63 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
125 int uid = DeviceUtils.getAppUid(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in testChangeFromInstallation()
154 int uid = DeviceUtils.getAppUid(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in testChangeFromReinstall()
172 int uid = DeviceUtils.getAppUid(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in testChangeFromUninstall()
/packages/modules/StatsD/tests/src/android/cts/statsd/alarm/
DAlarmTests.java23 import android.cts.statsdatom.lib.DeviceUtils;
61 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
74 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
84 DeviceUtils.turnScreenOn(getDevice()); in testAlarm()
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/role/ui/specialappaccess/
DSpecialAppAccessListActivity.java24 import com.android.permissioncontroller.DeviceUtils;
37 if (DeviceUtils.isAuto(this)) { in onCreate()
46 if (DeviceUtils.isAuto(this)) { in onCreate()
DSpecialAppAccessActivity.java29 import com.android.permissioncontroller.DeviceUtils;
59 if (DeviceUtils.isAuto(this)) { in onCreate()
88 if (DeviceUtils.isAuto(this)) { in onCreate()
/packages/modules/OnDevicePersonalization/tests/federatedcomputetests/src/com/android/federatedcompute/services/
DFederatedComputeBroadcastReceiverTest.java36 import com.android.odp.module.common.DeviceUtils;
55 .spyStatic(DeviceUtils.class)
66 ExtendedMockito.doReturn(true).when(() -> DeviceUtils.isOdpSupported(any())); in setup()
111 ExtendedMockito.doReturn(false).when(() -> DeviceUtils.isOdpSupported(any())); in testOnReceiveDeviceNotSupported()
/packages/modules/StatsD/tests/src/android/cts/statsd/atom/
DProcStateTestCase.java23 import android.cts.statsdatom.lib.DeviceUtils;
76 DeviceUtils.installTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_APK, in setUp()
85 DeviceUtils.uninstallTestApp(getDevice(), MetricsUtils.DEVICE_SIDE_TEST_PACKAGE); in tearDown()
/packages/modules/OnDevicePersonalization/src/com/android/ondevicepersonalization/services/
DOnDevicePersonalizationBroadcastReceiver.java28 import com.android.odp.module.common.DeviceUtils;
78 if (!DeviceUtils.isOdpSupported(context)) { in onReceive()
112 if (FlagsFactory.getFlags().getGlobalKillSwitch() || !DeviceUtils.isOdpSupported(context)) { in restoreOdpJobs()
DOnDevicePersonalizationManagingServiceDelegate.java37 import com.android.odp.module.common.DeviceUtils;
75 if (!DeviceUtils.isOdpSupported(mContext)) { in execute()
121 if (!DeviceUtils.isOdpSupported(mContext)) { in requestSurfacePackage()
161 if (!DeviceUtils.isOdpSupported(mContext)) { in registerMeasurementEvent()
/packages/modules/OnDevicePersonalization/common/java/com/android/odp/module/common/
DDeviceUtils.java28 public class DeviceUtils { class
40 private DeviceUtils() {} in DeviceUtils() method in DeviceUtils
/packages/modules/Permission/PermissionController/src/com/android/permissioncontroller/permission/utils/v35/
DMultiDeviceUtils.kt33 import com.android.permissioncontroller.DeviceUtils in <lambda>()
57 !(DeviceUtils.isTelevision(context) || in <lambda>()
58 DeviceUtils.isAuto(context) || in <lambda>()
59 DeviceUtils.isWear(context)) in <lambda>()

123