Add missing settings strings.

Also re-enable and fix tests.

Test: manual
Fixes: 226183482
Fixes: 218799125
Fixes: 219375624

Change-Id: I9605f1f4e2e834baf63e015e96639567c5481b5f
This commit is contained in:
Jonathan Scott
2022-04-11 09:49:17 +00:00
parent afe6d302e4
commit b7f4f56cad
63 changed files with 470 additions and 88 deletions

View File

@@ -18,9 +18,11 @@ package com.android.settings.inputmethod;
import static com.google.common.truth.Truth.assertThat;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
import android.app.admin.DevicePolicyManager;
import android.content.Context;
import android.content.res.Resources;
import android.view.textservice.SpellCheckerInfo;
@@ -59,6 +61,8 @@ public class SpellCheckerPreferenceControllerTest {
mAppContext = RuntimeEnvironment.application;
when(mContext.getSystemService(Context.TEXT_SERVICES_MANAGER_SERVICE))
.thenReturn(mTextServicesManager);
doReturn(mock(DevicePolicyManager.class)).when(mContext)
.getSystemService(Context.DEVICE_POLICY_SERVICE);
when(mContext.getResources()).thenReturn(mResources);
when(mResources.getBoolean(R.bool.config_show_spellcheckers_settings)).thenReturn(true);
mPreference = new Preference(mAppContext);