Merge remote-tracking branch 'origin/main' into rjm/1027-groups-permissions-logging

This commit is contained in:
Rachid Mrad 2023-10-03 18:46:22 -04:00
commit 3ea1f5aa77
No known key found for this signature in database
GPG key ID: EF38E4CEC4A8F3CF
16 changed files with 952 additions and 141 deletions

View file

@ -619,6 +619,16 @@ class MockEppLib(TestCase):
# use this for when a contact is being updated
# sets the second send() to fail
raise RegistryError(code=ErrorCode.OBJECT_EXISTS)
elif (
isinstance(_request, commands.DeleteDomain)
and getattr(_request, "name", None) == "failDelete.gov"
):
name = getattr(_request, "name", None)
fake_nameserver = "ns1.failDelete.gov"
if name in fake_nameserver:
raise RegistryError(
code=ErrorCode.OBJECT_ASSOCIATION_PROHIBITS_OPERATION
)
return MagicMock(res_data=[self.mockDataInfoHosts])
def setUp(self):