mirror of
https://github.com/google/nomulus.git
synced 2025-06-27 23:03:34 +02:00
Statically import commonly used TldState enum values
Takes advantage of the fact that the default state of a TLD created in tests is GENERAL_AVAILABILITY. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=228916164
This commit is contained in:
parent
eeb65b4610
commit
170980db2f
14 changed files with 62 additions and 63 deletions
|
@ -19,6 +19,8 @@ import static com.google.common.base.Preconditions.checkNotNull;
|
|||
import static com.google.common.base.Preconditions.checkState;
|
||||
import static com.google.common.collect.ImmutableList.toImmutableList;
|
||||
import static google.registry.model.ofy.ObjectifyService.ofy;
|
||||
import static google.registry.model.registry.Registry.TldState.GENERAL_AVAILABILITY;
|
||||
import static google.registry.model.registry.Registry.TldState.START_DATE_SUNRISE;
|
||||
import static google.registry.util.DateTimeUtils.START_OF_TIME;
|
||||
|
||||
import com.google.common.collect.ImmutableList;
|
||||
|
@ -113,9 +115,9 @@ public final class OteAccountBuilder {
|
|||
RegistryEnvironment.get() != RegistryEnvironment.PRODUCTION,
|
||||
"Can't setup OT&E in production");
|
||||
clientIdToTld = createClientIdToTldMap(baseClientId);
|
||||
sunriseTld = createTld(baseClientId + "-sunrise", TldState.START_DATE_SUNRISE, false, 0);
|
||||
gaTld = createTld(baseClientId + "-ga", TldState.GENERAL_AVAILABILITY, false, 2);
|
||||
eapTld = createTld(baseClientId + "-eap", TldState.GENERAL_AVAILABILITY, true, 3);
|
||||
sunriseTld = createTld(baseClientId + "-sunrise", START_DATE_SUNRISE, false, 0);
|
||||
gaTld = createTld(baseClientId + "-ga", GENERAL_AVAILABILITY, false, 2);
|
||||
eapTld = createTld(baseClientId + "-eap", GENERAL_AVAILABILITY, true, 3);
|
||||
registrars =
|
||||
clientIdToTld.keySet().stream()
|
||||
.map(OteAccountBuilder::createRegistrar)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue