1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.apache.commons.jelly.core;
17
18 /*** Tests for basic memory leaking in core tags. Runs a few test scripts many times.
19 * @author Hans Gilde
20 *
21 */
22 public class TestCoreMemoryLeak extends BaseMemoryLeakTest {
23
24 /*** The JUnit constructor.
25 * @param name
26 */
27 public TestCoreMemoryLeak(String name) {
28 super(name);
29 }
30
31 public void testBasicScriptForLeak() throws Exception {
32 assertTrue("Leak in core library", runScriptManyTimes("c.jelly", 10000) < 200000);
33 }
34
35 public void testIncludeTagForLeak() throws Exception {
36 assertTrue("Leak in include tag", runScriptManyTimes("a.jelly", 10000) < 200000);
37 }
38
39 }