use of org.eclipse.xtext.preferences.MapBasedPreferenceValues in project xtext-xtend by eclipse.
the class XtendAnnotationTypeFormatterTest method formatField01.
@Test
public void formatField01() {
final Procedure1<MapBasedPreferenceValues> _function = (MapBasedPreferenceValues it) -> {
};
StringConcatenation _builder = new StringConcatenation();
_builder.append("annotation Bar {");
_builder.newLine();
_builder.append("\t");
_builder.append("int foo");
_builder.newLine();
_builder.append("}");
_builder.newLine();
this.assertFormatted(_function, _builder);
}
use of org.eclipse.xtext.preferences.MapBasedPreferenceValues in project xtext-xtend by eclipse.
the class XtendAnnotationTypeFormatterTest method formatAbstract.
@Test
public void formatAbstract() {
final Procedure1<MapBasedPreferenceValues> _function = (MapBasedPreferenceValues it) -> {
};
StringConcatenation _builder = new StringConcatenation();
_builder.append("abstract annotation Bar {");
_builder.newLine();
_builder.append("}");
_builder.newLine();
this.assertFormatted(_function, _builder);
}
use of org.eclipse.xtext.preferences.MapBasedPreferenceValues in project xtext-xtend by eclipse.
the class XtendAnnotationTypeFormatterTest method formatPublic.
@Test
public void formatPublic() {
final Procedure1<MapBasedPreferenceValues> _function = (MapBasedPreferenceValues it) -> {
};
StringConcatenation _builder = new StringConcatenation();
_builder.append("public annotation Bar {");
_builder.newLine();
_builder.append("}");
_builder.newLine();
this.assertFormatted(_function, _builder);
}
use of org.eclipse.xtext.preferences.MapBasedPreferenceValues in project xtext-xtend by eclipse.
the class XtendAnnotationTypeFormatterTest method formatFieldInit01.
@Ignore
@Test
public void formatFieldInit01() {
final Procedure1<MapBasedPreferenceValues> _function = (MapBasedPreferenceValues it) -> {
};
StringConcatenation _builder = new StringConcatenation();
_builder.append("annotation Bar {");
_builder.newLine();
_builder.append("\t");
_builder.append("int foo = 1 + 1");
_builder.newLine();
_builder.append("}");
_builder.newLine();
this.assertFormatted(_function, _builder);
}
use of org.eclipse.xtext.preferences.MapBasedPreferenceValues in project xtext-xtend by eclipse.
the class XtendAnnotationsFormatterTest method formatClassSingleAnnotationSL.
@Test
public void formatClassSingleAnnotationSL() {
final Procedure1<MapBasedPreferenceValues> _function = (MapBasedPreferenceValues it) -> {
it.<Boolean>put(XbaseFormatterPreferenceKeys.newLineAfterClassAnnotations, Boolean.valueOf(false));
it.<Boolean>put(XbaseFormatterPreferenceKeys.preserveNewLines, Boolean.valueOf(true));
};
StringConcatenation _builder = new StringConcatenation();
_builder.append("package foo");
_builder.newLine();
_builder.newLine();
_builder.append("@Deprecated class bar {");
_builder.newLine();
_builder.append("}");
_builder.newLine();
StringConcatenation _builder_1 = new StringConcatenation();
_builder_1.append("package foo @Deprecated class bar { }");
_builder_1.newLine();
this.assertFormatted(_function, _builder, _builder_1);
}
Aggregations