diff options
Diffstat (limited to 'tests/src/com/android/inputmethod/latin/InputTestsBase.java')
-rw-r--r-- | tests/src/com/android/inputmethod/latin/InputTestsBase.java | 26 |
1 files changed, 2 insertions, 24 deletions
diff --git a/tests/src/com/android/inputmethod/latin/InputTestsBase.java b/tests/src/com/android/inputmethod/latin/InputTestsBase.java index 838effe2c..c73a931ea 100644 --- a/tests/src/com/android/inputmethod/latin/InputTestsBase.java +++ b/tests/src/com/android/inputmethod/latin/InputTestsBase.java @@ -107,31 +107,15 @@ public class InputTestsBase extends ServiceTestCase<LatinIME> { return setBooleanPreference(PREF_DEBUG_MODE, value, false); } - // overload this to configure preferences in a way specific to a subclass's tests - protected void configurePreferences() { - // please avoid changing preferences any more than is necessary, as an interruption - // during a test will leave the user's preferences in a bad state. - } - - // restore any preferences set in configurePreferences() - protected void restorePreferences() { - // undo any effects from configurePreferences() - } - @Override - protected void setUp() { - try { - super.setUp(); - } catch (Exception e) { - e.printStackTrace(); - } + protected void setUp() throws Exception { + super.setUp(); mTextView = new TextView(getContext()); mTextView.setInputType(InputType.TYPE_CLASS_TEXT); mTextView.setEnabled(true); setupService(); mLatinIME = getService(); final boolean previousDebugSetting = setDebugMode(true); - configurePreferences(); mLatinIME.onCreate(); setDebugMode(previousDebugSetting); initSubtypeMap(); @@ -153,12 +137,6 @@ public class InputTestsBase extends ServiceTestCase<LatinIME> { changeLanguage("en_US"); } - @Override - protected void tearDown() throws Exception { - super.tearDown(); - restorePreferences(); - } - private void initSubtypeMap() { final InputMethodManager imm = (InputMethodManager)mLatinIME.getSystemService( Context.INPUT_METHOD_SERVICE); |