[Python-checkins] CVS: python/dist/src/Lib/test test_email.py,1.17,1.18 test_rfc822.py,1.13,1.14

Barry Warsaw bwarsaw@users.sourceforge.net
Tue, 13 Nov 2001 10:01:39 -0800


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

Modified Files:
	test_email.py test_rfc822.py 
Log Message:
Add tests for bug #478115, parsedate_tz() IndexError when a Date:
field exists with an empty value.


Index: test_email.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/test_email.py,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** test_email.py	2001/11/09 19:31:34	1.17
--- test_email.py	2001/11/13 18:01:37	1.18
***************
*** 938,941 ****
--- 938,944 ----
              self.assertEqual(offset, toff)
  
+     def test_parsedate(self):
+         self.assertEqual(Utils.parsedate(''), None)
+ 
  
  

Index: test_rfc822.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/test_rfc822.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** test_rfc822.py	2001/09/20 21:33:42	1.13
--- test_rfc822.py	2001/11/13 18:01:37	1.14
***************
*** 119,122 ****
--- 119,130 ----
  
          self.check(
+             'To: Some One <someone@dom.ain>\n'
+             'From: Anudder Persin <subuddy.else@dom.ain>\n'
+             'Date:\n'
+             '\n'
+             'test',
+             [('Some One', 'someone@dom.ain')])
+ 
+         self.check(
              'To: person@dom.ain (User J. Person)\n\n',
              [('User J. Person', 'person@dom.ain')])