[Python-checkins] python/dist/src/Lib/test test_sgmllib.py,1.5,1.6

fdrake@users.sourceforge.net fdrake@users.sourceforge.net
Tue, 29 Apr 2003 15:12:59 -0700


Update of /cvsroot/python/python/dist/src/Lib/test
In directory sc8-pr-cvs1:/tmp/cvs-serv1015/test

Modified Files:
	test_sgmllib.py 
Log Message:
Allow "@" in unquoted attribute values.
Added test that checks for characters allowed in the query part of URLs.
Backport candidate.


Index: test_sgmllib.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/test_sgmllib.py,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** test_sgmllib.py	14 Mar 2003 16:21:57 -0000	1.5
--- test_sgmllib.py	29 Apr 2003 22:12:55 -0000	1.6
***************
*** 201,204 ****
--- 201,213 ----
              ("starttag", "a", [("b", ""), ("c", "")]),
              ])
+         # URL construction stuff from RFC 1808:
+         safe = "$-_.+"
+         extra = "!*'(),"
+         reserved = ";/?:@&="
+         url = "http://example.com:8080/path/to/file?%s%s%s" % (
+             safe, extra, reserved)
+         self.check_events("""<e a=%s>""" % url, [
+             ("starttag", "e", [("a", url)]),
+             ])
          # Regression test for SF patch #669683.
          self.check_events("<e a=rgb(1,2,3)>", [