[Zope3-checkins] CVS: Zope3/src/zope/publisher/tests - test_http.py:1.27

Stephan Richter srichter at cosmos.phy.tufts.edu
Thu Mar 18 15:03:56 EST 2004


Update of /cvs-repository/Zope3/src/zope/publisher/tests
In directory cvs.zope.org:/tmp/cvs-serv24927/src/zope/publisher/tests

Modified Files:
	test_http.py 
Log Message:


Added support for encoded unicode-containing URLs.


=== Zope3/src/zope/publisher/tests/test_http.py 1.26 => 1.27 ===
--- Zope3/src/zope/publisher/tests/test_http.py:1.26	Mon Mar 15 15:42:13 2004
+++ Zope3/src/zope/publisher/tests/test_http.py	Thu Mar 18 15:03:56 2004
@@ -1,3 +1,4 @@
+# -*- coding: latin-1 -*-
 ##############################################################################
 #
 # Copyright (c) 2001, 2002 Zope Corporation and Contributors.
@@ -344,9 +345,16 @@
         req._environ = {'SERVER_NAME': 'example.com'}
         self.assertEquals(deduceServerURL(), 'http://example.com')
 
+    def testUnicodeURLs(self):
+        req = self._createRequest(
+            {'PATH_INFO': '/%C3%A4%C3%B6/%C3%BC%C3%9F/foo/bar.html'})
+        self.assertEqual(req._traversal_stack,
+                         [u'bar.html', u'foo', u'üß', u'äö'])
+
 
 class ConcreteHTTPTests(HTTPTests):
-    """Tests that we don't have to worry about subclasses inheriting and breaking
+    """Tests that we don't have to worry about subclasses inheriting and
+    breaking.
     """
 
     def test_shiftNameToApplication(self):




More information about the Zope3-Checkins mailing list