summaryrefslogtreecommitdiff
path: root/tests/sitemaps_tests/test_http.py
diff options
context:
space:
mode:
authorchex <levisolympus@gmail.com>2017-02-25 17:54:17 +0500
committerTim Graham <timograham@gmail.com>2017-02-25 07:54:17 -0500
commit12745d8a4f89b00f360cb6102a25ab244135098c (patch)
tree12b4b107f5a00e37ec7619b7e334e457fc9a2784 /tests/sitemaps_tests/test_http.py
parentb427f0d674362d22c063852754914d9315cbc2fa (diff)
Added tests for contrib.sitemaps.GenericSitemap.
Diffstat (limited to 'tests/sitemaps_tests/test_http.py')
-rw-r--r--tests/sitemaps_tests/test_http.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/sitemaps_tests/test_http.py b/tests/sitemaps_tests/test_http.py
index 8a5c399eed..42962bb01c 100644
--- a/tests/sitemaps_tests/test_http.py
+++ b/tests/sitemaps_tests/test_http.py
@@ -4,7 +4,7 @@ from unittest import skipUnless
from django.apps import apps
from django.conf import settings
-from django.contrib.sitemaps import GenericSitemap, Sitemap
+from django.contrib.sitemaps import Sitemap
from django.contrib.sites.models import Site
from django.core.exceptions import ImproperlyConfigured
from django.test import modify_settings, override_settings
@@ -190,7 +190,8 @@ class HTTPSitemapTests(SitemapTestsBase):
Check to make sure that the raw item is included with each
Sitemap.get_url() url result.
"""
- test_sitemap = GenericSitemap({'queryset': TestModel.objects.order_by('pk').all()})
+ test_sitemap = Sitemap()
+ test_sitemap.items = TestModel.objects.order_by('pk').all
def is_testmodel(url):
return isinstance(url['item'], TestModel)