1 11 package org.eclipse.jdt.internal.junit.ui; 12 13 import java.util.List ; 14 15 import org.eclipse.core.runtime.Preferences; 16 import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer; 17 18 22 public class JunitPreferenceInitializer extends AbstractPreferenceInitializer { 23 24 25 public void initializeDefaultPreferences() { 26 Preferences prefs= JUnitPlugin.getDefault().getPluginPreferences(); 27 prefs.setDefault(JUnitPreferencesConstants.DO_FILTER_STACK, true); 28 prefs.setDefault(JUnitPreferencesConstants.SHOW_ON_ERROR_ONLY, false); 29 prefs.setDefault(JUnitPreferencesConstants.ENABLE_ASSERTIONS, false); 30 31 List defaults= JUnitPreferencesConstants.createDefaultStackFiltersList(); 32 String [] filters= (String []) defaults.toArray(new String [defaults.size()]); 33 String active= JUnitPreferencesConstants.serializeList(filters); 34 prefs.setDefault(JUnitPreferencesConstants.PREF_ACTIVE_FILTERS_LIST, active); 35 prefs.setDefault(JUnitPreferencesConstants.PREF_INACTIVE_FILTERS_LIST, ""); prefs.setDefault(JUnitPreferencesConstants.MAX_TEST_RUNS, 10); 37 38 prefs.setDefault(JUnitPreferencesConstants.JUNIT3_JAVADOC, "http://www.junit.org/junit/javadoc/3.8.1"); prefs.setDefault(JUnitPreferencesConstants.JUNIT4_JAVADOC, "http://www.junit.org/junit/javadoc/4.3"); } 41 } 42 | Popular Tags |