aboutsummaryrefslogtreecommitdiff
path: root/velocity-engine-core/src/test/resources/templates/curly-directive.vm
blob: 3da1fa38d20829b4e0c4f06e55486fc434395da6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#*

Check to see if directives with curly braces around them parse properly.

*#

#{if} (true)
    this is a test
#{elseif} (true)
    more text
#{else}
    this is a test
#end

## a more realistic example
#if(true)sometext#{else}more text#{end}and yet more

### others
#{set} ($a = 3)

#{macro}(mymacro)
    hello
#{end}

#{mymacro}()

#foreach ($a in [1..3])x#{end}

## Check escaped directives

\#if
\#else
\#elseif
\#set