Fix completion proposal labels
This commit is contained in:
@@ -170,7 +170,7 @@ public class PropertyCompletionFactory {
|
||||
|
||||
@Override
|
||||
public String getLabel() {
|
||||
return getBaseDisplayString() + " : " + typeUtil.niceTypeName(getType());
|
||||
return getBaseDisplayString();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -23,12 +23,6 @@ import com.google.common.collect.ImmutableList.Builder;
|
||||
|
||||
public abstract class AbstractPropertyRenderableProvider {
|
||||
|
||||
/**
|
||||
* Fake host name that is used in 'action link' urls so that we can
|
||||
* recognize them as such.
|
||||
*/
|
||||
private static final String ACTION_HOST = "action";
|
||||
|
||||
public Renderable getRenderable() {
|
||||
Builder<Renderable> renderableBuilder = ImmutableList.builder();
|
||||
|
||||
@@ -103,9 +97,8 @@ public abstract class AbstractPropertyRenderableProvider {
|
||||
* link then the provided runnable is to be executed.
|
||||
*/
|
||||
public void actionLink(Builder<Renderable> renderableBuilder, String displayString) {
|
||||
String url = "http://"+ACTION_HOST+"/action-id";
|
||||
renderableBuilder.add(lineBreak());
|
||||
renderableBuilder.add(link(displayString, url));
|
||||
renderableBuilder.add(link(displayString, "null"));
|
||||
}
|
||||
|
||||
private void defaultValueRenderable(Builder<Renderable> renderableBuilder, String defaultValue) {
|
||||
|
||||
@@ -70,7 +70,7 @@ public class ApplicationPropertiesEditorTest extends AbstractPropsEditorTest {
|
||||
@Test public void testServerPortCompletion() throws Exception {
|
||||
data("server.port", INTEGER, 8080, "Port where server listens for http.");
|
||||
assertCompletion("ser<*>", "server.port=<*>");
|
||||
assertCompletionDisplayString("ser<*>", "server.port : int");
|
||||
assertCompletionDisplayString("ser<*>", "server.port");
|
||||
}
|
||||
|
||||
@Test public void testLoggingLevelCompletion() throws Exception {
|
||||
@@ -1501,7 +1501,7 @@ public class ApplicationPropertiesEditorTest extends AbstractPropsEditorTest {
|
||||
"some.property=SOMETHING\n" +
|
||||
"<*>"
|
||||
, // ===============
|
||||
"some.other.property : String"
|
||||
"some.other.property"
|
||||
, // =>
|
||||
"some.property=SOMETHING\n" +
|
||||
"some.other.property=<*>"
|
||||
|
||||
Reference in New Issue
Block a user