use of org.eclipse.xtext.xbase.impl.XbaseFactoryImpl in project xtext-xtend by eclipse.
the class JavaConverterTest method testForceStatementForTargetObject.
@Test
public void testForceStatementForTargetObject() {
Assert.assertFalse("Not a statement before annotation", this.j2x.shouldForceStatementMode(new XAnnotationsFactoryImpl().createXAnnotation()));
final XtendConstructor xc = new XtendFactoryImpl().createXtendConstructor();
Assert.assertFalse("Not a statement before constructor", this.j2x.shouldForceStatementMode(xc));
final XBlockExpression block = new XbaseFactoryImpl().createXBlockExpression();
xc.setExpression(block);
Assert.assertTrue("Force statement when parent is executable", this.j2x.shouldForceStatementMode(block));
}
Aggregations