Add SEO data generation and testing for bilingual pages
- Implemented SEO data structures for programmatic tool and collection pages. - Created functions to build FAQs and content sections for SEO pages. - Added tests to ensure at least 50 bilingual SEO pages are generated, no duplicate English slugs, and matching Arabic localized paths. - Verified that both tool and collection SEO inventories are populated adequately.
This commit is contained in:
13
backend/tests/test_sitemap.py
Normal file
13
backend/tests/test_sitemap.py
Normal file
@@ -0,0 +1,13 @@
|
||||
"""Tests for XML sitemap exposure."""
|
||||
|
||||
|
||||
def test_sitemap_endpoint(client):
|
||||
response = client.get('/sitemap.xml')
|
||||
assert response.status_code == 200
|
||||
assert 'xml' in response.content_type
|
||||
|
||||
body = response.get_data(as_text=True)
|
||||
assert 'https://dociva.io/tools/pdf-to-word' in body
|
||||
assert 'https://dociva.io/pdf-to-word' in body
|
||||
assert 'https://dociva.io/ar/pdf-to-word' in body
|
||||
assert 'https://dociva.io/arabic-pdf-tools' in body
|
||||
Reference in New Issue
Block a user