@@ -16,7 +16,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
1616 .subscriptionId(" subscription_id" )
1717 .addAdd(
1818 SubscriptionPriceIntervalsParams .Add .builder()
19- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
19+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
2020 .allocationPrice(
2121 NewAllocationPrice .builder()
2222 .amount(" 10.00" )
@@ -43,7 +43,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
4343 )
4444 .canDeferBilling(true )
4545 .addAmountDiscount(0.0 )
46- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
46+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
4747 .externalPriceId(" external_price_id" )
4848 .filter(" my_property > 100 AND my_other_property = 'bar'" )
4949 .addFixedFeeQuantityTransition(
@@ -116,7 +116,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
116116 )
117117 .addAddAdjustment(
118118 SubscriptionPriceIntervalsParams .AddAdjustment .builder()
119- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
119+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
120120 .adjustment(
121121 NewPercentageDiscount .builder()
122122 .adjustmentType(
@@ -141,7 +141,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
141141 .build()
142142 )
143143 .adjustmentId(" h74gfhdjvn7ujokd" )
144- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
144+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
145145 .build()
146146 )
147147 .allowInvoiceCreditOrVoid(true )
@@ -151,7 +151,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
151151 .priceIntervalId(" sdfs6wdjvn7ujokd" )
152152 .billingCycleDay(0L )
153153 .canDeferBilling(true )
154- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
154+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
155155 .filter(" my_property > 100 AND my_other_property = 'bar'" )
156156 .addFixedFeeQuantityTransition(
157157 SubscriptionPriceIntervalsParams .Edit .FixedFeeQuantityTransition .builder()
@@ -164,15 +164,15 @@ internal class SubscriptionPriceIntervalsParamsTest {
164164 .putAdditionalProperty(" foo" , JsonValue .from(" bar" ))
165165 .build()
166166 )
167- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
167+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
168168 .addUsageCustomerId(" string" )
169169 .build()
170170 )
171171 .addEditAdjustment(
172172 SubscriptionPriceIntervalsParams .EditAdjustment .builder()
173173 .adjustmentIntervalId(" sdfs6wdjvn7ujokd" )
174- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
175- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
174+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
175+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
176176 .build()
177177 )
178178 .build()
@@ -195,7 +195,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
195195 .subscriptionId(" subscription_id" )
196196 .addAdd(
197197 SubscriptionPriceIntervalsParams .Add .builder()
198- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
198+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
199199 .allocationPrice(
200200 NewAllocationPrice .builder()
201201 .amount(" 10.00" )
@@ -222,7 +222,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
222222 )
223223 .canDeferBilling(true )
224224 .addAmountDiscount(0.0 )
225- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
225+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
226226 .externalPriceId(" external_price_id" )
227227 .filter(" my_property > 100 AND my_other_property = 'bar'" )
228228 .addFixedFeeQuantityTransition(
@@ -298,7 +298,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
298298 )
299299 .addAddAdjustment(
300300 SubscriptionPriceIntervalsParams .AddAdjustment .builder()
301- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
301+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
302302 .adjustment(
303303 NewPercentageDiscount .builder()
304304 .adjustmentType(
@@ -323,7 +323,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
323323 .build()
324324 )
325325 .adjustmentId(" h74gfhdjvn7ujokd" )
326- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
326+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
327327 .build()
328328 )
329329 .allowInvoiceCreditOrVoid(true )
@@ -333,7 +333,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
333333 .priceIntervalId(" sdfs6wdjvn7ujokd" )
334334 .billingCycleDay(0L )
335335 .canDeferBilling(true )
336- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
336+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
337337 .filter(" my_property > 100 AND my_other_property = 'bar'" )
338338 .addFixedFeeQuantityTransition(
339339 SubscriptionPriceIntervalsParams .Edit .FixedFeeQuantityTransition
@@ -347,15 +347,15 @@ internal class SubscriptionPriceIntervalsParamsTest {
347347 .putAdditionalProperty(" foo" , JsonValue .from(" bar" ))
348348 .build()
349349 )
350- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
350+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
351351 .addUsageCustomerId(" string" )
352352 .build()
353353 )
354354 .addEditAdjustment(
355355 SubscriptionPriceIntervalsParams .EditAdjustment .builder()
356356 .adjustmentIntervalId(" sdfs6wdjvn7ujokd" )
357- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
358- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
357+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
358+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
359359 .build()
360360 )
361361 .build()
@@ -365,7 +365,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
365365 assertThat(body.add().getOrNull())
366366 .containsExactly(
367367 SubscriptionPriceIntervalsParams .Add .builder()
368- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
368+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
369369 .allocationPrice(
370370 NewAllocationPrice .builder()
371371 .amount(" 10.00" )
@@ -392,7 +392,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
392392 )
393393 .canDeferBilling(true )
394394 .addAmountDiscount(0.0 )
395- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
395+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
396396 .externalPriceId(" external_price_id" )
397397 .filter(" my_property > 100 AND my_other_property = 'bar'" )
398398 .addFixedFeeQuantityTransition(
@@ -466,7 +466,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
466466 assertThat(body.addAdjustments().getOrNull())
467467 .containsExactly(
468468 SubscriptionPriceIntervalsParams .AddAdjustment .builder()
469- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
469+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
470470 .adjustment(
471471 NewPercentageDiscount .builder()
472472 .adjustmentType(
@@ -491,7 +491,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
491491 .build()
492492 )
493493 .adjustmentId(" h74gfhdjvn7ujokd" )
494- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
494+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
495495 .build()
496496 )
497497 assertThat(body.allowInvoiceCreditOrVoid()).contains(true )
@@ -502,7 +502,7 @@ internal class SubscriptionPriceIntervalsParamsTest {
502502 .priceIntervalId(" sdfs6wdjvn7ujokd" )
503503 .billingCycleDay(0L )
504504 .canDeferBilling(true )
505- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
505+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
506506 .filter(" my_property > 100 AND my_other_property = 'bar'" )
507507 .addFixedFeeQuantityTransition(
508508 SubscriptionPriceIntervalsParams .Edit .FixedFeeQuantityTransition .builder()
@@ -515,16 +515,16 @@ internal class SubscriptionPriceIntervalsParamsTest {
515515 .putAdditionalProperty(" foo" , JsonValue .from(" bar" ))
516516 .build()
517517 )
518- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
518+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
519519 .addUsageCustomerId(" string" )
520520 .build()
521521 )
522522 assertThat(body.editAdjustments().getOrNull())
523523 .containsExactly(
524524 SubscriptionPriceIntervalsParams .EditAdjustment .builder()
525525 .adjustmentIntervalId(" sdfs6wdjvn7ujokd" )
526- .endDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
527- .startDate(OffsetDateTime .parse( " 2019-12-27T18:11:19.117Z " ) )
526+ .endDate(BillingCycleRelativeDate . START_OF_TERM )
527+ .startDate(BillingCycleRelativeDate . START_OF_TERM )
528528 .build()
529529 )
530530 }
0 commit comments