| | | 1 | fs.addFilter("test", "@test1@");↵
|
1 | fs.addFilter("test1","@test2@");↵ | | 2 | fs.addFilter("test1","@test2@");↵
|
2 | fs.addFilter("test2", "@test@");↵ | | 3 | fs.addFilter("test2", "↵
|
3 | fs.addFilter("test3", "testvalue");↵ | | 4 | it works");↵
|
4 | fs.setBeginToken("@");↵ | | 5 | fs.setBeginToken("@");↵
|
5 | fs.setEndToken("@");↵ | | 6 | fs.setEndToken("@");↵
|
6 | assertEquals(result, fs.replaceTokens(line));↵ | | 7 | assertEquals(result, fs.replaceTokens(line));↵
|
7 | }↵ | | 8 | }↵
|
|
8 | /**↵ | | 9 | /**↵
|
9 | * Test to see what happens when the resolving occurs in↵ | | 10 | * Test to see what happens when the resolving occurs in an↵
|
10 | * what would be an infinite loop, but with recursion disabled.↵ | | 11 | * infinite loop.↵
|
11 | */↵ | | 12 | */↵
|
12 | public void testRecursionDisabled() {↵ | | 13 | public void testInfinite() {↵
|
13 | String result = "@test1@ line testvalue";↵ | | 14 | String result = "@test@ line testvalue";↵
|
14 | String line = "@test@ line @test2@";↵ | | 15 | String line = "@test@ line @test3@";↵
|
15 | FilterSet fs = new FilterSet();↵ | | 16 | FilterSet fs = new FilterSet();↵
|
16 | fs.addFilter("test", "@test1@");↵ | | 17 | fs.addFilter("test", "@test1@");↵
|
17 | fs.addFilter("test1","@test@");↵ | | 18 | fs.addFilter("test1","@test2@");↵
|
18 | fs.addFilter("test2", "testvalue");↵ | | 19 | fs.addFilter("test2", "@test@");↵
|
19 | fs | | 20 | fs
|