Load referenced contact/hosts from EPP more efficiently

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=122459862
This commit is contained in:
cgoldfeder 2016-05-16 14:34:26 -07:00 committed by Justine Tunney
parent 86f3287761
commit 618050dc32
11 changed files with 113 additions and 64 deletions

View file

@ -57,8 +57,8 @@ import google.registry.flows.domain.BaseDomainUpdateFlow.MaxSigLifeChangeNotSupp
import google.registry.flows.domain.BaseDomainUpdateFlow.SecDnsAllUsageException;
import google.registry.flows.domain.BaseDomainUpdateFlow.UrgentAttributeNotSupportedException;
import google.registry.flows.domain.DomainFlowUtils.DuplicateContactForRoleException;
import google.registry.flows.domain.DomainFlowUtils.LinkedResourceDoesNotExistException;
import google.registry.flows.domain.DomainFlowUtils.LinkedResourceInPendingDeleteProhibitsOperationException;
import google.registry.flows.domain.DomainFlowUtils.LinkedResourcesDoNotExistException;
import google.registry.flows.domain.DomainFlowUtils.MissingAdminContactException;
import google.registry.flows.domain.DomainFlowUtils.MissingContactTypeException;
import google.registry.flows.domain.DomainFlowUtils.MissingTechnicalContactException;
@ -858,7 +858,7 @@ public class DomainUpdateFlowTest extends ResourceFlowTestCase<DomainUpdateFlow,
@Test
public void testFailure_missingHost() throws Exception {
thrown.expect(
LinkedResourceDoesNotExistException.class,
LinkedResourcesDoNotExistException.class,
"(ns2.example.foo)");
persistActiveHost("ns1.example.foo");
persistActiveContact("sh8013");
@ -870,7 +870,7 @@ public class DomainUpdateFlowTest extends ResourceFlowTestCase<DomainUpdateFlow,
@Test
public void testFailure_missingContact() throws Exception {
thrown.expect(
LinkedResourceDoesNotExistException.class,
LinkedResourcesDoNotExistException.class,
"(sh8013)");
persistActiveHost("ns1.example.foo");
persistActiveHost("ns2.example.foo");