Fix some task quirks

This commit is contained in:
2026-03-08 23:16:15 +00:00
parent acedc01e83
commit a7421b9350
7 changed files with 312 additions and 34 deletions

View File

@@ -223,6 +223,44 @@ class TasksPagesManagementTests(TestCase):
).exists()
)
def test_group_page_does_not_seed_source_for_malformed_whatsapp_asset_path(self):
response = self.client.get(
reverse(
"tasks_group",
kwargs={
"service": "whatsapp",
"identifier": "447777695114/static/js/template_profiler.js",
},
)
)
self.assertEqual(200, response.status_code)
self.assertFalse(
ChatTaskSource.objects.filter(
user=self.user,
service="whatsapp",
channel_identifier__icontains="template_profiler.js",
).exists()
)
def test_group_page_does_not_seed_source_for_malformed_signal_asset_path(self):
response = self.client.get(
reverse(
"tasks_group",
kwargs={
"service": "signal",
"identifier": "group.c0VHQTlGMEhRL2V5/static/js/template_profiler.js",
},
)
)
self.assertEqual(200, response.status_code)
self.assertFalse(
ChatTaskSource.objects.filter(
user=self.user,
service="signal",
channel_identifier__icontains="template_profiler.js",
).exists()
)
def test_tasks_hub_shows_human_creator_label(self):
project = TaskProject.objects.create(user=self.user, name="Creator Test")
session = ChatSession.objects.create(user=self.user, identifier=self.pid_signal)