From 5537f965ece29b766efe17c1d2137c3d2037811c Mon Sep 17 00:00:00 2001 From: Baptiste Mispelon Date: Fri, 22 Nov 2024 23:45:50 +0100 Subject: [PATCH] Fixed sponsor notes appearing on download page Thanks to user TheEpic-dev on the forum for reporting the issue. This was introduced in c024b32f65a48b6366baf2930e43c5f2014b1ace --- djangoproject/templates/releases/download.html | 2 +- releases/tests.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/djangoproject/templates/releases/download.html b/djangoproject/templates/releases/download.html index 592245df9..1ee32f117 100644 --- a/djangoproject/templates/releases/download.html +++ b/djangoproject/templates/releases/download.html @@ -276,7 +276,7 @@

Diamond and Platinum Members

diff --git a/releases/tests.py b/releases/tests.py index 36e6da2b2..9796e879a 100644 --- a/releases/tests.py +++ b/releases/tests.py @@ -174,7 +174,7 @@ def make_member(self, level, level_name): display_name=f"{level_name} Member", url=f"https://{level_name.lower()}.example.com", membership_level=level, - notes=f"Some notes about this {level_name} member", + description=f"Some notes about this {level_name} member", ) # ensure each member is included in `for_public_display` member.invoice_set.create( @@ -195,13 +195,13 @@ def test_diamond_and_platinum_members_shown(self): self.assertContains(response, "

Diamond and Platinum Members

") member_link = ( - lambda m: f'{m.notes}' + lambda m: f'{m.description}' ) for member in members: if member.membership_level < PLATINUM_MEMBERSHIP: self.assertNotContains(response, member.display_name) self.assertNotContains(response, member.url) - self.assertNotContains(response, member.notes) + self.assertNotContains(response, member.description) else: self.assertContains(response, member_link(member), html=True) @@ -218,4 +218,4 @@ def test_no_diamond_and_platinum_members(self): for member in members: self.assertNotContains(response, member.display_name) self.assertNotContains(response, member.url) - self.assertNotContains(response, member.notes) + self.assertNotContains(response, member.description)