[Python-3000-checkins] r55512 - python/branches/py3k-struni/Lib/test/test_calendar.py
walter.doerwald
python-3000-checkins at python.org
Tue May 22 19:03:44 CEST 2007
Author: walter.doerwald
Date: Tue May 22 19:03:39 2007
New Revision: 55512
Modified:
python/branches/py3k-struni/Lib/test/test_calendar.py
Log:
The HTMLCalendar outputs bytes now, so fix the test
accordingly (bytes.strip() always requires an argument).
Modified: python/branches/py3k-struni/Lib/test/test_calendar.py
==============================================================================
--- python/branches/py3k-struni/Lib/test/test_calendar.py (original)
+++ python/branches/py3k-struni/Lib/test/test_calendar.py Tue May 22 19:03:39 2007
@@ -194,9 +194,11 @@
)
def test_output_htmlcalendar(self):
+ encoding = 'ascii'
+ cal = calendar.HTMLCalendar()
self.assertEqual(
- calendar.HTMLCalendar().formatyearpage(2004).strip(),
- result_2004_html.strip()
+ cal.formatyearpage(2004, encoding=encoding).strip(b' \t\n'),
+ result_2004_html.strip(' \t\n').encode(encoding)
)
More information about the Python-3000-checkins
mailing list