changed UpdateDomain on nameserver.setter to be called with all the added/removed hosts in one call

This commit is contained in:
Alysia Broddrick 2023-10-09 21:13:49 -07:00
parent 65cf774e84
commit ffede9817f
No known key found for this signature in database
GPG key ID: 03917052CD0F06B7
4 changed files with 122 additions and 105 deletions

View file

@ -784,9 +784,12 @@ class MockEppLib(TestCase):
res_data=[self.mockDataHostChange],
code=ErrorCode.COMMAND_COMPLETED_SUCCESSFULLY,
)
# elif isinstance(_request, commands.UpdateHost):
# if getattr(_request, "name", None) == "ns1.failednameserver.gov":
# raise RegistryError(code=ErrorCode.OBJECT_EXISTS)
elif isinstance(_request, commands.UpdateHost):
return MagicMock(
res_data=[self.mockDataHostChange],
code=ErrorCode.COMMAND_COMPLETED_SUCCESSFULLY,
)
elif isinstance(_request, commands.UpdateDomain):
return MagicMock(
res_data=[self.mockDataHostChange],
code=ErrorCode.COMMAND_COMPLETED_SUCCESSFULLY,