mirror of
https://github.com/google/nomulus
synced 2026-09-19 14:34:18 +00:00
Add and wire up the AllocationTokenExtension XML class
The extension itself isn't used for anything yet; allocation tokens can be passed for domain creates and checks but are ignored if present. This will be changed in a subsequent CL that adds AllocationToken entities and related logic. Usage of this extension in any other EPP flow will throw an UnsupportedExtensionException. The relevant spec is https://tools.ietf.org/html/draft-gould-allocation-token-04 ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=181343188
This commit is contained in:
@@ -54,6 +54,7 @@ import com.google.common.collect.ImmutableSet;
|
||||
import com.google.common.collect.ImmutableSortedMap;
|
||||
import com.googlecode.objectify.Key;
|
||||
import google.registry.flows.EppException;
|
||||
import google.registry.flows.EppException.UnimplementedExtensionException;
|
||||
import google.registry.flows.EppRequestSource;
|
||||
import google.registry.flows.ResourceFlowTestCase;
|
||||
import google.registry.flows.ResourceFlowUtils.ResourceDoesNotExistException;
|
||||
@@ -1077,4 +1078,11 @@ public class DomainDeleteFlowTest extends ResourceFlowTestCase<DomainDeleteFlow,
|
||||
CommitMode.LIVE, UserPrivileges.SUPERUSER, loadFile("domain_delete_response.xml"));
|
||||
assertThat(reloadResourceByForeignKey()).isNull();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testFailure_allocationTokenNotSupportedOnDelete() throws Exception {
|
||||
setEppInput("domain_delete_allocationtoken.xml");
|
||||
EppException thrown = expectThrows(UnimplementedExtensionException.class, this::runFlow);
|
||||
assertAboutEppExceptions().that(thrown).marshalsToXml();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user