Mercurial > piecrust2
diff piecrust/processing/sitemap.py @ 979:45ad976712ec
tests: Big push to get the tests to pass again.
- Lots of fixes everywhere in the code.
- Try to handle debug logging in the multiprocessing worker pool when running in pytest. Not perfect, but usable for now.
- Replace all `.md` test files with `.html` since now a auto-format extension always sets the format.
- Replace `out` with `outfiles` in most places since now blog archives are added to the bake output and I don't want to add expected outputs for blog archives everywhere.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Sun, 29 Oct 2017 22:51:57 -0700 |
parents | 08e02c2a2a1a |
children | 727110ea112a |
line wrap: on
line diff
--- a/piecrust/processing/sitemap.py Sun Oct 29 22:46:41 2017 -0700 +++ b/piecrust/processing/sitemap.py Sun Oct 29 22:51:57 2017 -0700 @@ -11,17 +11,17 @@ SITEMAP_HEADER = \ - """<?xml version="1.0" encoding="utf-8"?> - <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> - """ +"""<?xml version="1.0" encoding="utf-8"?> +<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> +""" SITEMAP_FOOTER = "</urlset>\n" -SITEURL_HEADER = " <url>\n" -SITEURL_LOC = " <loc>%s</loc>\n" -SITEURL_LASTMOD = " <lastmod>%s</lastmod>\n" -SITEURL_CHANGEFREQ = " <changefreq>%s</changefreq>\n" -SITEURL_PRIORITY = " <priority>%0.1f</priority>\n" -SITEURL_FOOTER = " </url>\n" +SITEURL_HEADER = " <url>\n" # NOQA: E222 +SITEURL_LOC = " <loc>%s</loc>\n" # NOQA: E222 +SITEURL_LASTMOD = " <lastmod>%s</lastmod>\n" # NOQA: E222 +SITEURL_CHANGEFREQ = " <changefreq>%s</changefreq>\n" # NOQA: E222 +SITEURL_PRIORITY = " <priority>%0.1f</priority>\n" # NOQA: E222 +SITEURL_FOOTER = " </url>\n" # NOQA: E222 class SitemapProcessor(SimpleFileProcessor):