mirror of
https://github.com/google/nomulus.git
synced 2025-07-20 17:56:08 +02:00
Delete end-date sunrise, landrush, and sunrush phases
This also deletes the associated commands and domain application specific entities. We haven't used any of these TLD phases since early 2015 and have no intent to do so in the future, so it makes sense to delete them now so we don't have to carry them through the Registry 3.0 migration. Note that, while there are data model changes, there should be no required data migrations. The fields and entities being removed will simply remain as orphans. I confirmed that the removed types (such as the SUNRUSH_ADD GracePeriodType) are no longer used in production data, and left types that are still used, e.g. BillingEvent.Flag.LANDRUSH or HistoryEntry.Type.ALLOCATE. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=228752843
This commit is contained in:
parent
c74ffd7559
commit
580302898d
282 changed files with 344 additions and 17634 deletions
|
@ -18,6 +18,9 @@ import static google.registry.model.EppResourceUtils.loadByForeignKey;
|
|||
import static google.registry.model.eppoutput.Result.Code.SUCCESS;
|
||||
import static google.registry.model.eppoutput.Result.Code.SUCCESS_AND_CLOSE;
|
||||
import static google.registry.model.eppoutput.Result.Code.SUCCESS_WITH_ACTION_PENDING;
|
||||
import static google.registry.model.registry.Registry.TldState.GENERAL_AVAILABILITY;
|
||||
import static google.registry.model.registry.Registry.TldState.PREDELEGATION;
|
||||
import static google.registry.model.registry.Registry.TldState.START_DATE_SUNRISE;
|
||||
import static google.registry.testing.DatastoreHelper.assertBillingEventsForResource;
|
||||
import static google.registry.testing.DatastoreHelper.createTld;
|
||||
import static google.registry.testing.DatastoreHelper.createTlds;
|
||||
|
@ -29,6 +32,7 @@ import static org.joda.money.CurrencyUnit.USD;
|
|||
|
||||
import com.google.common.collect.ImmutableMap;
|
||||
import com.google.common.collect.ImmutableSortedMap;
|
||||
import com.google.common.collect.Ordering;
|
||||
import com.google.re2j.Matcher;
|
||||
import com.google.re2j.Pattern;
|
||||
import google.registry.model.billing.BillingEvent;
|
||||
|
@ -376,13 +380,11 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
DateTime sunriseDate = DateTime.parse("2000-05-30T00:00:00Z");
|
||||
createTld(
|
||||
"example",
|
||||
ImmutableSortedMap.of(
|
||||
START_OF_TIME,
|
||||
TldState.PREDELEGATION,
|
||||
sunriseDate,
|
||||
TldState.SUNRISE,
|
||||
sunriseDate.plusMonths(2),
|
||||
TldState.GENERAL_AVAILABILITY));
|
||||
new ImmutableSortedMap.Builder<DateTime, TldState>(Ordering.natural())
|
||||
.put(START_OF_TIME, PREDELEGATION)
|
||||
.put(sunriseDate, START_DATE_SUNRISE)
|
||||
.put(sunriseDate.plusMonths(2), GENERAL_AVAILABILITY)
|
||||
.build());
|
||||
|
||||
assertThatLoginSucceeds("NewRegistrar", "foo-BAR2");
|
||||
|
||||
|
@ -393,7 +395,8 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
.hasResponse(
|
||||
"response_error.xml",
|
||||
ImmutableMap.of(
|
||||
"CODE", "2002", "MSG", "Command is not allowed in the current registry phase"));
|
||||
"CODE", "2002",
|
||||
"MSG", "The current registry phase does not allow for general registrations"));
|
||||
|
||||
assertThatCommand("domain_info_testvalidate.xml")
|
||||
.atTime(sunriseDate.plusDays(1))
|
||||
|
@ -412,8 +415,8 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
createTld(
|
||||
"example",
|
||||
ImmutableSortedMap.of(
|
||||
START_OF_TIME, TldState.PREDELEGATION,
|
||||
gaDate, TldState.GENERAL_AVAILABILITY));
|
||||
START_OF_TIME, PREDELEGATION,
|
||||
gaDate, GENERAL_AVAILABILITY));
|
||||
|
||||
assertThatCommand("login_valid_fee_extension.xml").hasResponse("generic_success_response.xml");
|
||||
|
||||
|
@ -882,9 +885,9 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
createTld(
|
||||
"example",
|
||||
ImmutableSortedMap.of(
|
||||
START_OF_TIME, TldState.PREDELEGATION,
|
||||
sunriseDate, TldState.START_DATE_SUNRISE,
|
||||
gaDate, TldState.GENERAL_AVAILABILITY));
|
||||
START_OF_TIME, PREDELEGATION,
|
||||
sunriseDate, START_DATE_SUNRISE,
|
||||
gaDate, GENERAL_AVAILABILITY));
|
||||
|
||||
assertThatLogin("NewRegistrar", "foo-BAR2")
|
||||
.atTime(sunriseDate.minusDays(3))
|
||||
|
@ -898,13 +901,11 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
.hasResponse(
|
||||
"response_error.xml",
|
||||
ImmutableMap.of(
|
||||
"CODE", "2306",
|
||||
"MSG",
|
||||
"Declared launch extension phase does not match the current registry phase"));
|
||||
"CODE", "2002",
|
||||
"MSG", "The current registry phase does not allow for general registrations"));
|
||||
|
||||
assertThatCommand(
|
||||
"domain_create_no_hosts_or_dsdata.xml",
|
||||
ImmutableMap.of("DOMAIN", "general.example"))
|
||||
"domain_create_no_hosts_or_dsdata.xml", ImmutableMap.of("DOMAIN", "general.example"))
|
||||
.atTime(sunriseDate.minusDays(1))
|
||||
.hasResponse(
|
||||
"response_error.xml",
|
||||
|
@ -912,7 +913,17 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
"CODE", "2002",
|
||||
"MSG", "The current registry phase does not allow for general registrations"));
|
||||
|
||||
// During start-date sunrise, create with mark will succeed but without will fail.
|
||||
// During sunrise, verify that the launch phase must be set to sunrise.
|
||||
assertThatCommand("domain_create_start_date_sunrise_encoded_mark_wrong_phase.xml")
|
||||
.atTime(sunriseDate)
|
||||
.hasResponse(
|
||||
"response_error.xml",
|
||||
ImmutableMap.of(
|
||||
"CODE", "2306",
|
||||
"MSG",
|
||||
"Declared launch extension phase does not match the current registry phase"));
|
||||
|
||||
// During sunrise, create with mark will succeed but without will fail.
|
||||
// We also test we can delete without a mark.
|
||||
assertThatCommand("domain_create_start_date_sunrise_encoded_mark.xml")
|
||||
.atTime(sunriseDate.plusDays(1))
|
||||
|
@ -961,12 +972,7 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
assertThatLogoutSucceeds();
|
||||
}
|
||||
|
||||
/**
|
||||
* Test that missing type= argument on launch create works in start-date sunrise.
|
||||
*
|
||||
* <p>TODO(b/76095570):have the same exact test on end-date sunrise - using the same .xml file -
|
||||
* that checks that an application was created.
|
||||
*/
|
||||
/** Test that missing type= argument on launch create works in start-date sunrise. */
|
||||
@Test
|
||||
public void testDomainCreation_startDateSunrise_noType() throws Exception {
|
||||
// The signed mark is valid between 2013 and 2017
|
||||
|
@ -975,9 +981,9 @@ public class EppLifecycleDomainTest extends EppTestCase {
|
|||
createTld(
|
||||
"example",
|
||||
ImmutableSortedMap.of(
|
||||
START_OF_TIME, TldState.PREDELEGATION,
|
||||
sunriseDate, TldState.START_DATE_SUNRISE,
|
||||
gaDate, TldState.GENERAL_AVAILABILITY));
|
||||
START_OF_TIME, PREDELEGATION,
|
||||
sunriseDate, START_DATE_SUNRISE,
|
||||
gaDate, GENERAL_AVAILABILITY));
|
||||
|
||||
assertThatLogin("NewRegistrar", "foo-BAR2")
|
||||
.atTime(sunriseDate.minusDays(3))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue