Begin writing AUTO_RENEW flag alongside reason

Backfill [] to follow, and the Recurring billing events will eventually be replicated as OneTime via a regular job.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=119883652
This commit is contained in:
ctingue 2016-04-14 13:19:27 -07:00 committed by Justine Tunney
parent fbe076b5da
commit 4112bca925
18 changed files with 87 additions and 36 deletions

View file

@ -51,6 +51,7 @@ import com.google.domain.registry.flows.SingleResourceFlow.ResourceStatusProhibi
import com.google.domain.registry.flows.domain.DomainDeleteFlow.DomainToDeleteHasHostsException;
import com.google.domain.registry.flows.domain.DomainFlowUtils.NotAuthorizedForTldException;
import com.google.domain.registry.model.billing.BillingEvent;
import com.google.domain.registry.model.billing.BillingEvent.Flag;
import com.google.domain.registry.model.billing.BillingEvent.Reason;
import com.google.domain.registry.model.contact.ContactResource;
import com.google.domain.registry.model.domain.DomainResource;
@ -196,7 +197,8 @@ public class DomainDeleteFlowTest extends ResourceFlowTestCase<DomainDeleteFlow,
private BillingEvent.Recurring.Builder createAutorenewBillingEvent(String clientId) {
return new BillingEvent.Recurring.Builder()
.setReason(Reason.AUTO_RENEW)
.setReason(Reason.RENEW)
.setFlags(ImmutableSet.of(Flag.AUTO_RENEW))
.setTargetId("example.tld")
.setClientId(clientId)
.setEventTime(A_MONTH_FROM_NOW)