Merge main

This commit is contained in:
Rachid Mrad 2024-04-30 21:10:21 -04:00
commit a20a9154a6
No known key found for this signature in database
30 changed files with 1148 additions and 655 deletions

View file

@ -977,6 +977,26 @@ class TestDomainRequestAdmin(MockEppLib):
self.assertContains(response, "<td>Submitted</td>", count=1)
self.assertContains(response, "<td>In review</td>", count=2)
self.assertContains(response, "<td>Action needed</td>", count=1)
def test_collaspe_toggle_button_markup(self):
"""
Tests for the correct collapse toggle button markup
"""
# Create a fake domain request and domain
domain_request = completed_domain_request(status=DomainRequest.DomainRequestStatus.IN_REVIEW)
p = "adminpass"
self.client.login(username="superuser", password=p)
response = self.client.get(
"/admin/registrar/domainrequest/{}/change/".format(domain_request.pk),
follow=True,
)
# Make sure the page loaded, and that we're on the right page
self.assertEqual(response.status_code, 200)
self.assertContains(response, domain_request.requested_domain.name)
self.test_helper.assertContains(response, "<span>Show details</span>")
@less_console_noise_decorator
def test_analyst_can_see_and_edit_alternative_domain(self):
@ -3134,7 +3154,15 @@ class TestMyUserAdmin(TestCase):
request.user = create_user()
fieldsets = self.admin.get_fieldsets(request)
expected_fieldsets = (
(None, {"fields": ("status",)}),
(
None,
{
"fields": (
"status",
"verification_type",
)
},
),
("Personal Info", {"fields": ("first_name", "last_name", "email")}),
("Permissions", {"fields": ("is_active", "groups")}),
("Important dates", {"fields": ("last_login", "date_joined")}),