@Override protected void setUp() throws Exception { Hashtable<String, String> options = TestOptions.getDefaultOptions(); options.put(DefaultCodeFormatterConstants.FORMATTER_TAB_CHAR, JavaCore.SPACE); options.put(DefaultCodeFormatterConstants.FORMATTER_TAB_SIZE, "4"); options.put( DefaultCodeFormatterConstants.FORMATTER_INSERT_NEW_LINE_AFTER_ANNOTATION_ON_LOCAL_VARIABLE, JavaCore.DO_NOT_INSERT); JavaCore.setOptions(options); IPreferenceStore store = JavaPlugin.getDefault().getPreferenceStore(); store.setValue(PreferenceConstants.CODEGEN_ADD_COMMENTS, false); fJProject1 = Java18ProjectTestSetup.getProject(); StubUtility.setCodeTemplate(CodeTemplateContextType.METHODSTUB_ID, "", null); StubUtility.setCodeTemplate(CodeTemplateContextType.CONSTRUCTORSTUB_ID, "", null); fSourceFolder = JavaProjectHelper.addSourceContainer(fJProject1, "src"); }
@Override protected void setUp() throws Exception { fJProject1 = Java18ProjectTestSetup.getProject(); fJProject1.getProject().getFolder(ANNOTATION_PATH).create(true, true, null); fJProject1.setOption(JavaCore.COMPILER_ANNOTATION_NULL_ANALYSIS, JavaCore.ENABLED); }