summaryrefslogtreecommitdiff
path: root/tests/syndication_tests
diff options
context:
space:
mode:
authorTom Carrick <tom@carrick.eu>2020-07-14 13:32:24 +0200
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2020-09-14 08:41:59 +0200
commitbcc2befd0e9c1885e45b46d0b0bcdc11def8b249 (patch)
tree59fab69a3182286da87fcd6fe05a8ce0f4277a5a /tests/syndication_tests
parent71ae1ab0123582cc5bfe0f7d5f4cc19a9412f396 (diff)
downloaddjango-bcc2befd0e9c1885e45b46d0b0bcdc11def8b249.tar.gz
Fixed #31789 -- Added a new headers interface to HttpResponse.
Diffstat (limited to 'tests/syndication_tests')
-rw-r--r--tests/syndication_tests/tests.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/syndication_tests/tests.py b/tests/syndication_tests/tests.py
index d9456ed618..b763bba6cb 100644
--- a/tests/syndication_tests/tests.py
+++ b/tests/syndication_tests/tests.py
@@ -421,14 +421,14 @@ class SyndicationFeedTest(FeedTestCase):
Tests the Last-Modified header with naive publication dates.
"""
response = self.client.get('/syndication/naive-dates/')
- self.assertEqual(response['Last-Modified'], 'Tue, 26 Mar 2013 01:00:00 GMT')
+ self.assertEqual(response.headers['Last-Modified'], 'Tue, 26 Mar 2013 01:00:00 GMT')
def test_feed_last_modified_time(self):
"""
Tests the Last-Modified header with aware publication dates.
"""
response = self.client.get('/syndication/aware-dates/')
- self.assertEqual(response['Last-Modified'], 'Mon, 25 Mar 2013 19:18:00 GMT')
+ self.assertEqual(response.headers['Last-Modified'], 'Mon, 25 Mar 2013 19:18:00 GMT')
# No last-modified when feed has no item_pubdate
response = self.client.get('/syndication/no_pubdate/')