Author: jezdez
Date: 2011-01-17 18:00:11 -0600 (Mon, 17 Jan 2011)
New Revision: 15237

Modified:
   
django/branches/releases/1.2.X/tests/regressiontests/test_client_regress/models.py
Log:
[1.2.X] Fixed #14468 -- Extended the list of content types that the test client 
could guess when handling zip files. Thanks, Russ and emulbreh.

Backport from trunk (r15236).

Modified: 
django/branches/releases/1.2.X/tests/regressiontests/test_client_regress/models.py
===================================================================
--- 
django/branches/releases/1.2.X/tests/regressiontests/test_client_regress/models.py
  2011-01-17 23:58:51 UTC (rev 15236)
+++ 
django/branches/releases/1.2.X/tests/regressiontests/test_client_regress/models.py
  2011-01-18 00:00:11 UTC (rev 15237)
@@ -844,8 +844,10 @@
                          encode_file('IGNORE', 'IGNORE', 
DummyFile("file.bin"))[2])
         self.assertEqual('Content-Type: text/plain',
                          encode_file('IGNORE', 'IGNORE', 
DummyFile("file.txt"))[2])
-        self.assertEqual('Content-Type: application/zip',
-                         encode_file('IGNORE', 'IGNORE', 
DummyFile("file.zip"))[2])
+        self.assertIn(encode_file('IGNORE', 'IGNORE', 
DummyFile("file.zip"))[2], (
+                        'Content-Type: application/x-compress',
+                        'Content-Type: application/x-zip',
+                        'Content-Type: application/x-zip-compressed'))
         self.assertEqual('Content-Type: application/octet-stream',
                          encode_file('IGNORE', 'IGNORE', 
DummyFile("file.unknown"))[2])
 

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.

Reply via email to