projects
/
jinja2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f5f8ffc
)
added unittest for the breakage i encountered today
author
Armin Ronacher
<armin.ronacher@active-4.com>
Sat, 8 Sep 2007 23:11:24 +0000
(
01:11
+0200)
committer
Armin Ronacher
<armin.ronacher@active-4.com>
Sat, 8 Sep 2007 23:11:24 +0000
(
01:11
+0200)
--HG--
branch : trunk
tests/test_filters.py
patch
|
blob
|
history
diff --git
a/tests/test_filters.py
b/tests/test_filters.py
index a3581ea5ec37ada9476d8344a429c8fa80d8b7a6..cc161949117fd204fd270374c85e02666553b28b 100644
(file)
--- a/
tests/test_filters.py
+++ b/
tests/test_filters.py
@@
-66,6
+66,7
@@
GROUPBY = '''{{ [{'foo': 1, 'bar': 2},
{'foo': 2, 'bar': 3},
{'foo': 1, 'bar': 1},
{'foo': 3, 'bar': 4}]|groupby('foo') }}'''
+FILTERTAG = '''{% filter upper|replace('FOO', 'foo') %}foobar{% endfilter %}'''
@@
-295,3
+296,8
@@
def test_groupby(env):
"'grouper': 1}, {'list': [{'foo': 2, 'bar': 3}], 'grouper': 2}, "
"{'list': [{'foo': 3, 'bar': 4}], 'grouper': 3}]"
)
+
+
+def test_filtertag(env):
+ tmpl = env.from_string(FILTERTAG)
+ assert tmpl.render() == 'fooBAR'