Merge "Remove extra argument WorkPolicyUtil constructor" into tm-dev

This commit is contained in:
Prabal Singh
2022-04-28 17:12:28 +00:00
committed by Android (Google) Code Review
2 changed files with 5 additions and 1 deletions

View File

@@ -69,7 +69,7 @@ public class EnterprisePrivacyFeatureProviderImpl implements EnterprisePrivacyFe
mCm = cm;
mVm = vm;
mResources = resources;
mWorkPolicyUtils = new WorkPolicyUtils(mContext, mPm, mUm, mDpm);
mWorkPolicyUtils = new WorkPolicyUtils(mContext);
}
@Override

View File

@@ -105,6 +105,10 @@ public class EnterprisePrivacyFeatureProviderImplTest {
when(mContext.getApplicationContext()).thenReturn(mContext);
resetAndInitializePackageManager();
when(mUserManager.getProfiles(mUserId)).thenReturn(mProfiles);
when(mContext.getSystemService(Context.DEVICE_POLICY_SERVICE))
.thenReturn(mDevicePolicyManager);
when(mContext.getSystemService(Context.USER_SERVICE)).thenReturn(mUserManager);
when(mContext.getPackageManager()).thenReturn(mPackageManager);
mProfiles.add(new UserInfo(mUserId, "", "", 0 /* flags */));
mResources = RuntimeEnvironment.application.getResources();