Add v2 registry uploads and source CSV exports
All checks were successful
CI/CD Pipeline / Quality Gate (push) Successful in 20s
CI/CD Pipeline / Build and Push Images (push) Successful in 10s
CI/CD Pipeline / Internal Notify (push) Successful in 0s
CI/CD Pipeline / Deploy Dev in Dokploy (push) Successful in 1s

This commit is contained in:
2026-05-07 14:39:20 +02:00
parent 507ae2063a
commit 15360a3c8e
13 changed files with 639 additions and 8 deletions

View File

@@ -151,3 +151,25 @@ class ParserDashboardPageTest(TestCase):
self.assertIn("На конец</th>", content)
self.assertIn("На начало</th>", content)
self.assertIn("Покрытие доп. данными", content)
def test_dashboard_uses_v2_registry_upload_routes(self):
response = self.client.get("/dashboard")
self.assertEqual(response.status_code, 200)
content = response.content.decode()
self.assertIn("REGISTRY_UPLOAD_SLUGS_BY_NAME", content)
self.assertIn("/api/v2/registers/${registrySlug}/upload/", content)
self.assertIn("/api/v2/registers/opk/upload/", content)
self.assertIn("registryUploadUrlForSelectedRegistry", content)
def test_dashboard_exposes_v2_source_csv_downloads(self):
response = self.client.get("/dashboard")
self.assertEqual(response.status_code, 200)
content = response.content.decode()
self.assertIn("function sourceCsvDownloadUrl", content)
self.assertIn("/api/v2/sources/${source.api_route}/download/", content)
self.assertIn("data-source-download", content)
self.assertIn("downloadSourceCsv", content)
self.assertIn("CSV", content)
self.assertNotIn("/api/v2/sources/fns/reports/download/", content)