Code

Ticket #18326: django-ticket18326.diff

File django-ticket18326.diff, 882 bytes (added by manfre, 2 years ago)
Line 
1diff --git a/tests/regressiontests/servers/tests.py b/tests/regressiontests/servers/tests.py
2index 5d287a1..e40ad30 100644
3--- a/tests/regressiontests/servers/tests.py
4+++ b/tests/regressiontests/servers/tests.py
5@@ -121,7 +121,7 @@ class LiveServerViews(LiveServerBase):
6         Refs #2879.
7         """
8         f = self.urlopen('/static/example_static_file.txt')
9-        self.assertEqual(f.read(), 'example static file\n')
10+        self.assertEqual(f.read().rstrip('\r\n'), 'example static file')
11 
12     def test_media_files(self):
13         """
14@@ -129,7 +129,7 @@ class LiveServerViews(LiveServerBase):
15         Refs #2879.
16         """
17         f = self.urlopen('/media/example_media_file.txt')
18-        self.assertEqual(f.read(), 'example media file\n')
19+        self.assertEqual(f.read().rstrip('\r\n'), 'example media file')
20 
21 
22 class LiveServerDatabase(LiveServerBase):