Opened 4 years ago

Closed 4 years ago

#15752 closed Bug (invalid)

test_simple_sitemap fails after executing test_requestsite_sitemap when Sites app is installed

Reported by: lucho Owned by: nobody
Component: contrib.sitemaps Version: 1.3
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

test_simple_sitemap fails after executing test_requestsite_sitemap when Sites app is installed.

 ======================================================================
 FAIL: test_simple_sitemap (django.contrib.sitemaps.tests.basic.SitemapTests)
 A simple sitemap can be rendered
 ----------------------------------------------------------------------
 Traceback (most recent call last):
   File "/usr/local/lib/python2.6/dist-packages/Django-1.3-py2.6.egg/django/contrib/sitemaps/tests/basic.py", line 70, in test_simple_sitemap
     """ % (self.base_url, date.today().strftime('%Y-%m-%d')))
 AssertionError: '<?xml version="1.0" encoding="UTF-8"?>\n<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">\n<url><loc>http://testserver/location/</loc><lastmod>2011-04-04</lastmod><changefreq>never</changefreq><priority>0.5</priority></url>\n</urlset>\n' != '<?xml version="1.0" encoding="UTF-8"?>\n<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">\n<url><loc>http://example.com/location/</loc><lastmod>2011-04-04</lastmod><changefreq>never</changefreq><priority>0.5</priority></url>\n</urlset>\n'
 


If I execute the test case separate (./manage.py test sitemaps.SitemapTests.test_simple_sitemap) no error is observed, but executing the whole test suite leads to error in test_simple_sitemap which is executed right after the test_requestsite_sitemap.

Change History (2)

comment:1 Changed 4 years ago by lucho

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

If I comment out the test_requestsite_sitemap, no problem is observed.

comment:2 Changed 4 years ago by lucho

  • Resolution set to invalid
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.
Back to Top