Preference setting to turn on/off TestJars support
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2015, 2017 Pivotal, Inc.
|
||||
* Copyright (c) 2015, 2024 Pivotal, Inc.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
@@ -44,6 +44,9 @@ public class BootPreferences implements IPreferenceChangeListener {
|
||||
public static final String PREF_BOOT_FAST_STARTUP_JVM_ARGS = "org.springframework.ide.eclipse.boot.FastStartupJvmArgs";
|
||||
public static final String BOOT_FAST_STARTUP_DEFAULT_JVM_ARGS = "-XX:TieredStopAtLevel=1";
|
||||
|
||||
public static final String PREF_BOOT_TESTJARS_LAUNCH_SUPPORT = "org.springframework.ide.eclipse.boot.TestJarsLaunch";
|
||||
|
||||
|
||||
// Boot Preference Page ID
|
||||
public static final String BOOT_PREFERENCE_PAGE_ID = "org.springframework.ide.eclipse.boot.ui.preferences.BootPreferencePage";
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2015, 2023 Pivotal, Inc.
|
||||
* Copyright (c) 2015, 2024 Pivotal, Inc.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
@@ -15,6 +15,7 @@ import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOO
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOOT_FAST_STARTUP_REMIND_MESSAGE;
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOOT_THIN_WRAPPER;
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_IGNORE_SILENT_EXIT;
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOOT_TESTJARS_LAUNCH_SUPPORT;
|
||||
|
||||
import org.eclipse.debug.internal.ui.preferences.BooleanFieldEditor2;
|
||||
import org.eclipse.jface.layout.GridDataFactory;
|
||||
@@ -71,6 +72,8 @@ public class BootPreferencePage extends FieldEditorPreferencePage implements IWo
|
||||
thinLauncher.setErrorMessage("Thin launcher must be an existing file");
|
||||
setTooltip(thinLauncherComposite, thinLauncher, "Thin boot launcher jar to use in Spring Boot Launch configuration (when that option is enabled in the launch config)");
|
||||
addField(thinLauncher);
|
||||
|
||||
addField(new BooleanFieldEditor2(PREF_BOOT_TESTJARS_LAUNCH_SUPPORT, "TestJars Support", SWT.CHECK, launchGroup));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2016, 2017 Pivotal, Inc.
|
||||
* Copyright (c) 2016, 2024 Pivotal, Inc.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
@@ -17,6 +17,7 @@ import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOO
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOOT_FAST_STARTUP_REMIND_MESSAGE;
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOOT_FAST_STARTUP_JVM_ARGS;
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.BOOT_FAST_STARTUP_DEFAULT_JVM_ARGS;
|
||||
import static org.springframework.ide.eclipse.boot.core.BootPreferences.PREF_BOOT_TESTJARS_LAUNCH_SUPPORT;
|
||||
|
||||
import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
|
||||
import org.eclipse.jface.preference.IPreferenceStore;
|
||||
@@ -25,7 +26,7 @@ import org.springsource.ide.eclipse.commons.core.preferences.StsProperties;
|
||||
|
||||
/**
|
||||
* Initializer of default values for the Spring Boot support
|
||||
*
|
||||
*
|
||||
* @author Alex Boyko
|
||||
*
|
||||
*/
|
||||
@@ -34,7 +35,7 @@ public class PreferencesInitializer extends AbstractPreferenceInitializer {
|
||||
@Override
|
||||
public void initializeDefaultPreferences() {
|
||||
IPreferenceStore store = BootActivator.getDefault().getPreferenceStore();
|
||||
|
||||
|
||||
/*
|
||||
* Note that line below cannot be moved to BootPreferencePage static
|
||||
* init method because the class has BooleanFieldEditor2 import that in
|
||||
@@ -42,13 +43,15 @@ public class PreferencesInitializer extends AbstractPreferenceInitializer {
|
||||
* because workbench may not be started in the case of a unit test
|
||||
*/
|
||||
store.setDefault(PREF_IGNORE_SILENT_EXIT, DEFAULT_PREF_IGNORE_SILENT_EXIT);
|
||||
|
||||
|
||||
store.setDefault(PREF_INITIALIZR_URL, StsProperties.getInstance().get("spring.initializr.json.url"));
|
||||
|
||||
|
||||
store.setDefault(PREF_BOOT_FAST_STARTUP_DEFAULT, true);
|
||||
store.setDefault(PREF_BOOT_FAST_STARTUP_REMIND_MESSAGE, true);
|
||||
store.setDefault(PREF_BOOT_FAST_STARTUP_JVM_ARGS, BOOT_FAST_STARTUP_DEFAULT_JVM_ARGS);
|
||||
store.setDefault(BOOT_FAST_STARTUP_DEFAULT_JVM_ARGS, DEFAULT_PREF_IGNORE_SILENT_EXIT);
|
||||
store.setDefault(PREF_BOOT_TESTJARS_LAUNCH_SUPPORT, true);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user