StandaloneExp extends Exp { @Override public abstract String getCode();  StandaloneExp append(StandaloneExp other); StandaloneExp append(NestedExp other); @Override abstract String getCode(); void insertBefore(CtBehavior behavior); void insertAfter(CtBehavior behavior); void insertCatch(CtClass exceptionType, CtBehavior behavior); void insertFinally(CtBehavior behavior); void replace(Expr expression); boolean isEmpty(); static final StandaloneExp PROCEED_AND_ASSIGN; }
@Test public void testProceed() { assertEquals("\n$_ = $proceed($$);", StandaloneExp.PROCEED_AND_ASSIGN.getCode()); }
@Test public void testCodeStandaloneExpFromStandalone() { StandaloneExp standaloneExp = CodeStandaloneExp.fromStandalone("someCode", false); assertEquals("someCode", standaloneExp.getCode()); }
@Test public void testCodeStandaloneExpFromNested() { assertEquals("\nsomeCode;", CodeStandaloneExp.fromNested("someCode").getCode()); }