@After public void tearDown() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void tearDown() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void tearDown() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void tearDown() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@After public void cleanup() { JinjavaInterpreter.popCurrent(); }
@Test public void itAllowsMacroRecursionWhenEnabledInConfiguration() throws IOException { // I need a different configuration here therefore interpreter = new Jinjava(JinjavaConfig.newBuilder().withEnableRecursiveMacroCalls(true).build()).newInterpreter(); JinjavaInterpreter.pushCurrent(interpreter); try { String template = fixtureText("ending-recursion"); String out = interpreter.render(template); assertThat(interpreter.getErrorsCopy()).isEmpty(); assertThat(out).contains("Hello Hello Hello Hello Hello"); } finally { // and I need to cleanup my mess... JinjavaInterpreter.popCurrent(); } }
@Test public void itAllowsMacroRecursionWhenEnabledInConfiguration() throws IOException { // I need a different configuration here therefore interpreter = new Jinjava(JinjavaConfig.newBuilder().withEnableRecursiveMacroCalls(true).build()).newInterpreter(); JinjavaInterpreter.pushCurrent(interpreter); try { String template = fixtureText("ending-recursion"); String out = interpreter.render(template); assertThat(interpreter.getErrorsCopy()).isEmpty(); assertThat(out).contains("Hello Hello Hello Hello Hello"); } finally { // and I need to cleanup my mess... JinjavaInterpreter.popCurrent(); } }
} finally { globalContext.reset(); JinjavaInterpreter.popCurrent();