From 715c00df76dc0caa7e70be5c7b5c85a4f35dc8a9 Mon Sep 17 00:00:00 2001 From: Ramiro Morales Date: Fri, 21 Jan 2011 01:37:08 +0000 Subject: [PATCH] [1.2.X] Fixed a regression in the test suite from [15236]. Backport of r15244. Also, changed an asertion not supported by unittest. git-svn-id: http://code.djangoproject.com/svn/django/branches/releases/1.2.X@15255 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- tests/regressiontests/test_client_regress/models.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/regressiontests/test_client_regress/models.py b/tests/regressiontests/test_client_regress/models.py index fd8fbfe90a..4197e81411 100644 --- a/tests/regressiontests/test_client_regress/models.py +++ b/tests/regressiontests/test_client_regress/models.py @@ -844,10 +844,11 @@ class UploadedFileEncodingTest(TestCase): encode_file('IGNORE', 'IGNORE', DummyFile("file.bin"))[2]) self.assertEqual('Content-Type: text/plain', encode_file('IGNORE', 'IGNORE', DummyFile("file.txt"))[2]) - self.assertIn(encode_file('IGNORE', 'IGNORE', DummyFile("file.zip"))[2], ( + self.assertTrue(encode_file('IGNORE', 'IGNORE', DummyFile("file.zip"))[2] in ( 'Content-Type: application/x-compress', 'Content-Type: application/x-zip', - 'Content-Type: application/x-zip-compressed')) + 'Content-Type: application/x-zip-compressed', + 'Content-Type: application/zip')) self.assertEqual('Content-Type: application/octet-stream', encode_file('IGNORE', 'IGNORE', DummyFile("file.unknown"))[2])