summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTres Seaver <tseaver@palladion.com>2009-04-08 12:35:42 +0000
committerTres Seaver <tseaver@palladion.com>2009-04-08 12:35:42 +0000
commitaa710fcd11141a2c269efdaa64d9c69a970d7147 (patch)
treead69e079a60092a51587d66ebacbdd570b9cfe33
parentfb7265e42442a822c2825f7118d6ff2eaf6c1d6b (diff)
downloadzope-tal-aa710fcd11141a2c269efdaa64d9c69a970d7147.tar.gz
Update tests of "bad" entities for compatibility with the stricter3.5.1
HTMLParser module shipped with Python 2.6.x. Prep 3.5.1 release.
-rw-r--r--CHANGES.txt7
-rw-r--r--setup.py2
-rw-r--r--src/zope/tal/tests/test_talinterpreter.py14
3 files changed, 18 insertions, 5 deletions
diff --git a/CHANGES.txt b/CHANGES.txt
index e979876..bf7ffe0 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -2,6 +2,13 @@
CHANGES
=======
+3.5.1 (2009-03-08)
+------------------
+
+- Updated tests of "bad" entities for compatibility with the stricter
+ HTMLParser module shipped with Python 2.6.x.
+
+
3.5.0 (2008-06-06)
------------------
diff --git a/setup.py b/setup.py
index 6937670..0cedd7f 100644
--- a/setup.py
+++ b/setup.py
@@ -41,7 +41,7 @@ def alltests():
return TestSuite(suites)
setup(name='zope.tal',
- version = '3.5.1dev',
+ version = '3.5.1',
author='Zope Corporation and Contributors',
author_email='zope-dev@zope.org',
description='Zope 3 Template Application Languate (TAL)',
diff --git a/src/zope/tal/tests/test_talinterpreter.py b/src/zope/tal/tests/test_talinterpreter.py
index 449fdcc..d7b73ca 100644
--- a/src/zope/tal/tests/test_talinterpreter.py
+++ b/src/zope/tal/tests/test_talinterpreter.py
@@ -706,10 +706,16 @@ class OutputPresentationTestCase(TestCaseBase):
self.compare(INPUT, EXPECTED)
def test_entities(self):
- INPUT = ('<img tal:define="foo nothing" '
- 'alt="&a; &#1; &#x0a; &a &#45 &; &#0a; <>" />')
- EXPECTED = ('<img alt="&a; &#1; &#x0a; '
- '&amp;a &amp;#45 &amp;; &amp;#0a; &lt;&gt;" />')
+ if sys.version_info < (2, 6):
+ INPUT = ('<img tal:define="foo nothing" '
+ 'alt="&a; &#1; &#x0a; &a &#45 &; &#0a; <>" />')
+ EXPECTED = ('<img alt="&a; &#1; &#x0a; '
+ '&amp;a &amp;#45 &amp;; &amp;#0a; &lt;&gt;" />')
+ else:
+ INPUT = ('<img tal:define="foo nothing" '
+ 'alt="&a; &#1; &#x0a; &a &#45 &; <>" />')
+ EXPECTED = ('<img alt="&a; \x01 \n '
+ '&amp;a &amp;#45 &amp;; &lt;&gt;" />')
self.compare(INPUT, EXPECTED)
def compare(self, INPUT, EXPECTED):