[PATCH] Add a test to verify escaped entities in #raw blocks
"R. Tyler Ballance" <[email protected]> Tue, 15 Dec 2009 00:02:17 -0800
| Newsgroups | gmane.comp.python.cheetah |
|---|---|
| Message-ID | <[email protected]> |
Related to 0cc9f78 and 70c9bd4
---
cheetah/Tests/SyntaxAndOutput.py | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/cheetah/Tests/SyntaxAndOutput.py b/cheetah/Tests/SyntaxAndOutput.py
index 452dcbb..66e8bd7 100644
--- a/cheetah/Tests/SyntaxAndOutput.py
+++ b/cheetah/Tests/SyntaxAndOutput.py
@@ -1359,6 +1359,12 @@ class RawDirective(OutputTest):
self.verify("#raw: $aFunc().\n$anInt",
"$aFunc().\n1")
+ def test6(self):
+ """ Escape characters in a #raw block """
+ self.verify( """#raw: This escape should be preserved: \\$unexpanded So should this one: \\#blah The string "\\012" should not disappear.""",
+ r"""This escape should be preserved: \$unexpanded So should this one: \#blah The string "\012" should not disappear.""")
+
+
class BreakpointDirective(OutputTest):
def test1(self):
"""#breakpoint part way through source code"""
--
1.6.5.3
------------------------------------------------------------------------------
Return on Information:
Google Enterprise Search pays you back
Get the facts.
http://p.sf.net/sfu/google-dev2dev